diff options
author | gspencer@chromium.org <gspencer@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-07-31 21:46:16 +0000 |
---|---|---|
committer | gspencer@chromium.org <gspencer@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-07-31 21:46:16 +0000 |
commit | 862ce989beae7c7e5be505e2d266606c6443f6e7 (patch) | |
tree | 68da4ccf95bd4aaf463de951a5b7865f83036a1a /chrome/browser/chromeos/cros/network_library.cc | |
parent | 2b4081c8a9ca113176e9f2a9b5470e7b63651c94 (diff) | |
download | chromium_src-862ce989beae7c7e5be505e2d266606c6443f6e7.zip chromium_src-862ce989beae7c7e5be505e2d266606c6443f6e7.tar.gz chromium_src-862ce989beae7c7e5be505e2d266606c6443f6e7.tar.bz2 |
This fixes connecting to hidden networks by not marking them failed
when they fail to show up in the wifi scan (they're hidden, so they
aren't expected to show up).
BUG=chromium:137273
TEST=Ran on device, tested connection to hidden network multiple times
with no failure.
Review URL: https://chromiumcodereview.appspot.com/10849003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@149283 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/chromeos/cros/network_library.cc')
-rw-r--r-- | chrome/browser/chromeos/cros/network_library.cc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/chrome/browser/chromeos/cros/network_library.cc b/chrome/browser/chromeos/cros/network_library.cc index 7f231dd..c9258f3 100644 --- a/chrome/browser/chromeos/cros/network_library.cc +++ b/chrome/browser/chromeos/cros/network_library.cc @@ -289,13 +289,16 @@ void Network::SetState(ConnectionState new_state) { // CONNECT_REQUESTED is set internally. Shill/flimflam do not update the // state immediately, so ignore any Idle state updates sent while a // connection attempt is in progress. + VLOG(2) << "Ignoring idle state change after connection request."; return; } ConnectionState old_state = state_; + VLOG(2) << "Entering new state: " << ConnectionStateString(new_state); state_ = new_state; if (!IsConnectingState(new_state)) set_connection_started(false); if (new_state == STATE_FAILURE) { + VLOG(2) << "Detected Failure state."; if (old_state != STATE_UNKNOWN && old_state != STATE_IDLE) { // New failure, the user needs to be notified. // Transition STATE_IDLE -> STATE_FAILURE sometimes happens on resume @@ -303,8 +306,10 @@ void Network::SetState(ConnectionState new_state) { notify_failure_ = true; // Normally error_ should be set, but if it is not we need to set it to // something here so that the retry logic will be triggered. - if (error_ == ERROR_NO_ERROR) + if (error_ == ERROR_NO_ERROR) { + VLOG(2) << "Detected NO_ERROR error state. Setting to UNKNOWN."; error_ = ERROR_UNKNOWN; + } } } else if (new_state != STATE_UNKNOWN) { notify_failure_ = false; |