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

Unified Diff: Source/core/xmlhttprequest/XMLHttpRequest.cpp

Issue 1060113004: [XMLHttpRequest] Stop throwing for network error in async mode (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 5 years, 6 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 | « LayoutTests/http/tests/xmlhttprequest/resources/cross-origin-unsupported-url.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/xmlhttprequest/XMLHttpRequest.cpp
diff --git a/Source/core/xmlhttprequest/XMLHttpRequest.cpp b/Source/core/xmlhttprequest/XMLHttpRequest.cpp
index d75347048676b26e778a719d20662e096684f8ac..393540ad6b53b2c57e9877e20ca66a4146efba83 100644
--- a/Source/core/xmlhttprequest/XMLHttpRequest.cpp
+++ b/Source/core/xmlhttprequest/XMLHttpRequest.cpp
@@ -1072,12 +1072,12 @@ void XMLHttpRequest::createRequest(PassRefPtr<FormData> httpBody, ExceptionState
// Use count for XHR synchronous requests.
UseCounter::count(&executionContext, UseCounter::XMLHttpRequestSynchronous);
ThreadableLoader::loadResourceSynchronously(executionContext, request, *this, options, resourceLoaderOptions);
- }
- if (!m_exceptionCode && m_error)
- m_exceptionCode = NetworkError;
- if (m_exceptionCode)
- exceptionState.throwDOMException(m_exceptionCode, "Failed to load '" + m_url.elidedString() + "'.");
+ if (!m_exceptionCode && m_error)
+ m_exceptionCode = NetworkError;
+ if (m_exceptionCode)
+ exceptionState.throwDOMException(m_exceptionCode, "Failed to load '" + m_url.elidedString() + "'.");
+ }
}
void XMLHttpRequest::abort()
« no previous file with comments | « LayoutTests/http/tests/xmlhttprequest/resources/cross-origin-unsupported-url.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698