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

Unified Diff: chrome/browser/resources/chromeos/wallpaper_manager/js/util.js

Issue 24040002: Fix unexpected error message when quickly select different wallpapers (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 3 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: chrome/browser/resources/chromeos/wallpaper_manager/js/util.js
diff --git a/chrome/browser/resources/chromeos/wallpaper_manager/js/util.js b/chrome/browser/resources/chromeos/wallpaper_manager/js/util.js
index bd63042c0d691dd03192d53d6998ba785264b643..a43e79e9a95372c74b748b7e1e2e7c03e1180f58 100644
--- a/chrome/browser/resources/chromeos/wallpaper_manager/js/util.js
+++ b/chrome/browser/resources/chromeos/wallpaper_manager/js/util.js
@@ -61,6 +61,11 @@ WallpaperUtil.fetchURL = function(url, type, onSuccess, onFailure, opt_xhr) {
xhr.addEventListener('loadend', function(e) {
if (this.status == 200) {
onSuccess(this);
+ } else if (this.status == 0) {
flackr 2013/09/06 15:44:00 A status of 0 can also result from a network error
+ // The status attribute may return 0 if this request is aborted when
+ // readystate is UNSENT or OPENED. No error message should show. See
+ // http://crbug.com/242581.
+ return;
} else {
onFailure();
}

Powered by Google App Engine
This is Rietveld 408576698