aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--dm/DM.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/dm/DM.cpp b/dm/DM.cpp
index d558e08ca6..6748544eca 100644
--- a/dm/DM.cpp
+++ b/dm/DM.cpp
@@ -262,6 +262,12 @@ static void gather_gold() {
/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
+#if defined(SK_BUILD_FOR_WIN32)
+ static const char* kNewline = "\r\n";
+#else
+ static const char* kNewline = "\n";
+#endif
+
static SkTHashSet<SkString> gUninterestingHashes;
static void gather_uninteresting_hashes() {
@@ -273,7 +279,7 @@ static void gather_uninteresting_hashes() {
return;
}
SkTArray<SkString> hashes;
- SkStrSplit((const char*)data->data(), "\n", &hashes);
+ SkStrSplit((const char*)data->data(), kNewline, &hashes);
for (const SkString& hash : hashes) {
gUninterestingHashes.add(hash);
}