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

Unified Diff: components/policy/core/common/registry_dict_win.cc

Issue 383263005: Remove more CreateIntegerValue calls. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: s/SetBoolean/SetInteger Created 6 years, 5 months 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: components/policy/core/common/registry_dict_win.cc
diff --git a/components/policy/core/common/registry_dict_win.cc b/components/policy/core/common/registry_dict_win.cc
index 8e03fbc4f722f136739d4a4220f0746103c42914..143956d754c92713a114a98782df1626f0e45608 100644
--- a/components/policy/core/common/registry_dict_win.cc
+++ b/components/policy/core/common/registry_dict_win.cc
@@ -79,8 +79,7 @@ scoped_ptr<base::Value> ConvertValue(const base::Value& value,
// Integers may be string-encoded.
if (value.GetAsString(&string_value) &&
base::StringToInt(string_value, &int_value)) {
- return scoped_ptr<base::Value>(
- base::Value::CreateIntegerValue(int_value));
+ return scoped_ptr<base::Value>(new base::FundamentalValue(int_value));
}
break;
}
@@ -264,8 +263,8 @@ void RegistryDict::ReadRegistry(HKEY hive, const base::string16& root) {
else
dword_value = base::ByteSwapToLE32(dword_value);
SetValue(name,
- scoped_ptr<base::Value>(
- base::Value::CreateIntegerValue(dword_value)));
+ scoped_ptr<base::Value>(new base::FundamentalValue(
+ static_cast<int>(dword_value))));
continue;
}
case REG_NONE:
« no previous file with comments | « components/policy/core/common/preg_parser_win.cc ('k') | components/policy/core/common/schema_map_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698