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

Unified Diff: chrome/browser/chromeos/proxy_config_service_impl.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 comments and rebased on a the current PART1 version. Created 9 years, 2 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: chrome/browser/chromeos/proxy_config_service_impl.cc
diff --git a/chrome/browser/chromeos/proxy_config_service_impl.cc b/chrome/browser/chromeos/proxy_config_service_impl.cc
index 399965d0f7421a6a7da0145cd7826b81977b2520..bfa7f9b0276ac146b77d59edfc8bb40d052269d2 100644
--- a/chrome/browser/chromeos/proxy_config_service_impl.cc
+++ b/chrome/browser/chromeos/proxy_config_service_impl.cc
@@ -656,16 +656,19 @@ net::ProxyConfigService::ConfigAvailability
void ProxyConfigServiceImpl::OnSettingsOpCompleted(
SignedSettings::ReturnCode code,
- std::string value) {
+ const base::Value& value) {
retrieve_property_op_ = NULL;
if (code != SignedSettings::SUCCESS) {
LOG(WARNING) << "Error retrieving proxy setting from device";
device_config_.clear();
return;
}
- VLOG(1) << "Retrieved proxy setting from device, value=[" << value << "]";
+ std::string policy_value;
+ value.GetAsString(&policy_value);
+ VLOG(1) << "Retrieved proxy setting from device, value=["
+ << policy_value << "]";
ProxyConfig device_config;
- if (!device_config.DeserializeForDevice(value) ||
+ if (!device_config.DeserializeForDevice(policy_value) ||
!device_config.SerializeForNetwork(&device_config_)) {
LOG(WARNING) << "Can't deserialize device setting or serialize for network";
device_config_.clear();

Powered by Google App Engine
This is Rietveld 408576698