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

Unified Diff: chrome/browser/ui/webui/options/chromeos/core_chromeos_options_handler.cc

Issue 8091002: PART2: Make SignedSettings use proper Value types instead of string all around the place. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressed the nits and rebased on ToT (which now has PART1 in). Created 9 years, 1 month 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: chrome/browser/ui/webui/options/chromeos/core_chromeos_options_handler.cc
diff --git a/chrome/browser/ui/webui/options/chromeos/core_chromeos_options_handler.cc b/chrome/browser/ui/webui/options/chromeos/core_chromeos_options_handler.cc
index 6af116a58cc00ddac184d9f411d5d98be8547b51..5a8807e19c8de134932e5ff96edee6c850504d8f 100644
--- a/chrome/browser/ui/webui/options/chromeos/core_chromeos_options_handler.cc
+++ b/chrome/browser/ui/webui/options/chromeos/core_chromeos_options_handler.cc
@@ -158,9 +158,7 @@ void CoreChromeOSOptionsHandler::SetPref(const std::string& pref_name,
if (!CrosSettings::IsCrosSettings(pref_name))
return ::CoreOptionsHandler::SetPref(pref_name, value, metric);
handling_change_ = true;
- // CrosSettings takes ownership of its value so we need to copy it.
- base::Value* pref_value = value->DeepCopy();
- CrosSettings::Get()->Set(pref_name, pref_value);
+ CrosSettings::Get()->Set(pref_name, *value);
handling_change_ = false;
ProcessUserMetric(value, metric);

Powered by Google App Engine
This is Rietveld 408576698