Bug 1318004 - Replace string literals containing escaped characters with raw string literals. draft
authorSylvestre Ledru <sledru@mozilla.com>
Wed, 16 Nov 2016 17:07:03 +0100
changeset 439789 952a2eb313fa3ad6873030387ee8d0a074a095f5
parent 439788 c39200ccccb311b3f53953a56d51f26e6ce67008
child 439790 e5c5d857a0613d003ad8b42d624f943d0bfbcdd3
push id36092
push usersledru@mozilla.com
push dateWed, 16 Nov 2016 16:14:46 +0000
bugs1318004
milestone53.0a1
Bug 1318004 - Replace string literals containing escaped characters with raw string literals. MozReview-Commit-ID: KOk13e23Py
toolkit/components/terminator/nsTerminator.cpp
--- a/toolkit/components/terminator/nsTerminator.cpp
+++ b/toolkit/components/terminator/nsTerminator.cpp
@@ -510,19 +510,19 @@ nsTerminator::UpdateTelemetry()
   for (auto & sShutdownStep : sShutdownSteps) {
     if (sShutdownStep.mTicks < 0) {
       // Ignore this field.
       continue;
     }
     if (fields++ > 0) {
       telemetryData->Append(", ");
     }
-    telemetryData->AppendLiteral("\"");
+    telemetryData->AppendLiteral(R"(")");
     telemetryData->Append(sShutdownStep.mTopic);
-    telemetryData->AppendLiteral("\": ");
+    telemetryData->AppendLiteral(R"(": )");
     telemetryData->AppendInt(sShutdownStep.mTicks);
   }
   telemetryData->AppendLiteral("}");
 
   if (fields == 0) {
     // Nothing to write
       return;
   }