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

Unified Diff: chrome/browser/chromeos/proxy_cros_settings_parser.cc

Issue 11418048: Add copy and assignment to FundamentalValue and StringValue. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 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/chromeos/proxy_cros_settings_parser.cc
diff --git a/chrome/browser/chromeos/proxy_cros_settings_parser.cc b/chrome/browser/chromeos/proxy_cros_settings_parser.cc
index 2177095abab29528781b3465515d30111d2e2457..5dc5e270340f4067c899d0ff9744933216606ce6 100644
--- a/chrome/browser/chromeos/proxy_cros_settings_parser.cc
+++ b/chrome/browser/chromeos/proxy_cros_settings_parser.cc
@@ -56,7 +56,7 @@ namespace {
base::Value* CreateServerHostValue(
const ProxyConfigServiceImpl::ProxyConfig::ManualProxy& proxy) {
return proxy.server.is_valid() ?
- base::Value::CreateStringValue(proxy.server.host_port_pair().host()) :
+ new base::StringValue(proxy.server.host_port_pair().host()) :
NULL;
}
@@ -298,8 +298,7 @@ bool GetProxyPrefValue(Profile* profile,
if (config.mode ==
chromeos::ProxyConfigServiceImpl::ProxyConfig::MODE_PAC_SCRIPT &&
config.automatic_proxy.pac_url.is_valid()) {
- data =
- base::Value::CreateStringValue(config.automatic_proxy.pac_url.spec());
+ data = new base::StringValue(config.automatic_proxy.pac_url.spec());
}
} else if (path == kProxySingleHttp) {
data = CreateServerHostValue(config.single_proxy);
@@ -357,7 +356,7 @@ bool GetProxyPrefValue(Profile* profile,
ListValue* list = new ListValue();
net::ProxyBypassRules::RuleList bypass_rules = config.bypass_rules.rules();
for (size_t x = 0; x < bypass_rules.size(); x++) {
- list->Append(base::Value::CreateStringValue(bypass_rules[x]->ToString()));
+ list->Append(new base::StringValue(bypass_rules[x]->ToString()));
}
data = list;
} else {
@@ -368,7 +367,7 @@ bool GetProxyPrefValue(Profile* profile,
// Decorate pref value as CoreOptionsHandler::CreateValueForPref() does.
DictionaryValue* dict = new DictionaryValue;
if (!data)
- data = base::Value::CreateStringValue("");
+ data = new base::StringValue("");
dict->Set("value", data);
if (path == kProxyType) {
dict->SetString("controlledBy", controlled_by);

Powered by Google App Engine
This is Rietveld 408576698