| Index: chromeos/network/network_connection_handler.cc
|
| ===================================================================
|
| --- chromeos/network/network_connection_handler.cc (revision 221717)
|
| +++ chromeos/network/network_connection_handler.cc (working copy)
|
| @@ -118,16 +118,10 @@
|
| const char NetworkConnectionHandler::kErrorAuthenticationRequired[] =
|
| "authentication-required";
|
| const char NetworkConnectionHandler::kErrorShillError[] = "shill-error";
|
| -const char NetworkConnectionHandler::kErrorConnectFailed[] = "connect-failed";
|
| const char NetworkConnectionHandler::kErrorConfigureFailed[] =
|
| "configure-failed";
|
| -const char NetworkConnectionHandler::kErrorActivateFailed[] =
|
| - "activate-failed";
|
| -const char NetworkConnectionHandler::kErrorMissingProvider[] =
|
| - "missing-provider";
|
| const char NetworkConnectionHandler::kErrorConnectCanceled[] =
|
| "connect-canceled";
|
| -const char NetworkConnectionHandler::kErrorUnknown[] = "unknown-error";
|
|
|
| struct NetworkConnectionHandler::ConnectRequest {
|
| ConnectRequest(const std::string& service_path,
|
| @@ -254,14 +248,8 @@
|
|
|
| if (check_error_state) {
|
| const std::string& error = network->error();
|
| - if (error == flimflam::kErrorConnectFailed) {
|
| - InvokeErrorCallback(
|
| - service_path, error_callback, kErrorPassphraseRequired);
|
| - return;
|
| - }
|
| if (error == flimflam::kErrorBadPassphrase) {
|
| - InvokeErrorCallback(
|
| - service_path, error_callback, kErrorPassphraseRequired);
|
| + InvokeErrorCallback(service_path, error_callback, error);
|
| return;
|
| }
|
| if (IsAuthenticationError(error)) {
|
| @@ -401,7 +389,7 @@
|
| flimflam::kHostProperty, &vpn_provider_host);
|
| }
|
| if (vpn_provider_type.empty() || vpn_provider_host.empty()) {
|
| - ErrorCallbackForPendingRequest(service_path, kErrorMissingProvider);
|
| + ErrorCallbackForPendingRequest(service_path, kErrorConfigurationRequired);
|
| return;
|
| }
|
| // VPN requires a host and username to be set.
|
| @@ -574,7 +562,7 @@
|
| network_handler::ErrorCallback error_callback = request->error_callback;
|
| pending_requests_.erase(service_path);
|
| network_handler::ShillErrorCallbackFunction(
|
| - kErrorConnectFailed, service_path, error_callback,
|
| + flimflam::kErrorConnectFailed, service_path, error_callback,
|
| dbus_error_name, dbus_error_message);
|
| }
|
|
|
| @@ -614,7 +602,7 @@
|
| error_name = kErrorConnectCanceled;
|
| error_detail = "";
|
| } else {
|
| - error_name = kErrorConnectFailed;
|
| + error_name = flimflam::kErrorConnectFailed;
|
| error_detail = network->error();
|
| if (error_detail.empty()) {
|
| if (network->connection_state() == flimflam::kStateFailure)
|
|
|