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

Unified Diff: chrome/browser/chromeos/cros/network_library.cc

Issue 7740022: [cros] Don't display error notification on strange network state transitions. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 4 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/cros/network_library.cc
diff --git a/chrome/browser/chromeos/cros/network_library.cc b/chrome/browser/chromeos/cros/network_library.cc
index a347ec714b32544bfe482bdd594efcbc1802d900..42d7a529cae32cd3db0e7144bd82bc3aa19bfd8f 100644
--- a/chrome/browser/chromeos/cros/network_library.cc
+++ b/chrome/browser/chromeos/cros/network_library.cc
@@ -215,8 +215,11 @@ void Network::SetState(ConnectionState new_state) {
ConnectionState old_state = state_;
state_ = new_state;
if (new_state == STATE_FAILURE) {
- if (old_state != STATE_UNKNOWN) {
+ 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
+ // but is not an actual failure as network device is not ready yet.
notify_failure_ = true;
}
} else {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698