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

Unified Diff: chromeos/dbus/shill_service_client_stub.cc

Issue 20087002: Add migration from CaCert NSS nicknames to PEM. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed indentation. Created 7 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: chromeos/dbus/shill_service_client_stub.cc
diff --git a/chromeos/dbus/shill_service_client_stub.cc b/chromeos/dbus/shill_service_client_stub.cc
index db59bf31f6368e949d0afa2995b4471250c69605..257d4bbbc918923e8dd23a8d35b058fd5e2b24b5 100644
--- a/chromeos/dbus/shill_service_client_stub.cc
+++ b/chromeos/dbus/shill_service_client_stub.cc
@@ -366,12 +366,28 @@ bool ShillServiceClientStub::SetServiceProperty(const std::string& service_path,
MoveServiceToIndex(service_path, 0, true);
}
}
- dict->SetWithoutPathExpansion(property, value.DeepCopy());
+ base::DictionaryValue new_properties;
+ std::string changed_property;
+ if (property == flimflam::kOpenVPNCaCertNSSProperty ||
+ property == flimflam::kOpenVPNCaCertNSSProperty) {
stevenjb 2013/07/29 17:53:03 Same property twice? I assume one should be kL2tpI
pneubeck (no reviews) 2013/08/05 08:51:22 Done.
+ // These properties are only nested within the Provider dictionary if read
+ // from Shill.
+ base::DictionaryValue* provider = new base::DictionaryValue;
+ provider->SetWithoutPathExpansion(property, value.DeepCopy());
+ new_properties.SetWithoutPathExpansion(flimflam::kProviderProperty,
+ provider);
+ changed_property = flimflam::kProviderProperty;
+ } else {
+ new_properties.SetWithoutPathExpansion(property, value.DeepCopy());
+ changed_property = property;
+ }
+
+ dict->MergeDictionary(&new_properties);
base::MessageLoop::current()->PostTask(
FROM_HERE,
base::Bind(&ShillServiceClientStub::NotifyObserversPropertyChanged,
weak_ptr_factory_.GetWeakPtr(),
- dbus::ObjectPath(service_path), property));
+ dbus::ObjectPath(service_path), changed_property));
return true;
}

Powered by Google App Engine
This is Rietveld 408576698