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

Unified Diff: chromeos/network/network_configuration_handler.cc

Issue 1779633002: Invoke createNetwork() callback with GUID, not service name (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix more trybot failures Created 4 years, 9 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/network/network_configuration_handler.cc
diff --git a/chromeos/network/network_configuration_handler.cc b/chromeos/network/network_configuration_handler.cc
index 4caf50c11e0234e09cd82319cd657ce9eca85533..0cb32db62cce56b983d05e004dba232520fb469c 100644
--- a/chromeos/network/network_configuration_handler.cc
+++ b/chromeos/network/network_configuration_handler.cc
@@ -279,7 +279,7 @@ void NetworkConfigurationHandler::ClearShillProperties(
void NetworkConfigurationHandler::CreateShillConfiguration(
const base::DictionaryValue& shill_properties,
NetworkConfigurationObserver::Source source,
- const network_handler::StringResultCallback& callback,
+ const network_handler::ServiceResultCallback& callback,
const network_handler::ErrorCallback& error_callback) {
ShillManagerClient* manager =
DBusThreadManager::Get()->GetShillManagerClient();
@@ -393,10 +393,15 @@ void NetworkConfigurationHandler::RunCreateNetworkCallback(
const std::string& profile_path,
NetworkConfigurationObserver::Source source,
scoped_ptr<base::DictionaryValue> configure_properties,
- const network_handler::StringResultCallback& callback,
+ const network_handler::ServiceResultCallback& callback,
const dbus::ObjectPath& service_path) {
- if (!callback.is_null())
- callback.Run(service_path.value());
+ if (!callback.is_null()) {
+ std::string guid;
+ configure_properties->GetStringWithoutPathExpansion(
+ ::onc::network_config::kGUID, &guid);
+ DCHECK(!guid.empty());
+ callback.Run(service_path.value(), guid);
+ }
FOR_EACH_OBSERVER(NetworkConfigurationObserver, observers_,
OnConfigurationCreated(service_path.value(), profile_path,
*configure_properties, source));
« no previous file with comments | « chromeos/network/network_configuration_handler.h ('k') | chromeos/network/network_configuration_handler_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698