Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2962)

Unified Diff: base/metrics/statistics_recorder.cc

Issue 100823007: Stop doing unnecessary UTF-8 to UTF-16 conversions in JSONWriter. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix ChromeOS page encodings Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: base/metrics/statistics_recorder.cc
diff --git a/base/metrics/statistics_recorder.cc b/base/metrics/statistics_recorder.cc
index 2753c0b2b6011d86fc7c14a1de70851364100a13..62617c5d804cbe20f7299b387e499fc96c1bcfc8 100644
--- a/base/metrics/statistics_recorder.cc
+++ b/base/metrics/statistics_recorder.cc
@@ -172,7 +172,7 @@ std::string StatisticsRecorder::ToJSON(const std::string& query) {
std::string output("{");
if (!query.empty()) {
output += "\"query\":";
- JsonDoubleQuote(query, true, &output);
+ EscapeJSONString(query, true, &output);
output += ",";
}
« no previous file with comments | « base/json/string_escape_unittest.cc ('k') | chrome/browser/chromeos/policy/configuration_policy_handler_chromeos.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698