diff options
author | Andras Becsi <andras.becsi@digia.com> | 2014-09-04 17:00:56 +0200 |
---|---|---|
committer | Michael Bruning <michael.bruning@digia.com> | 2014-09-05 11:39:01 +0200 |
commit | f57d74bf42bbeef2565e69fef45e1c0b55e89cbb (patch) | |
tree | a75569b5ca858253431b5326c8f1724e0ab592fa | |
parent | 1f95d6661f9d0323b67bb72fc144cb714ad0f46d (diff) |
Fix an assertion in net/url_request/url_request.cc:656
Instead of cancelling the request we have to set error to
net::ERR_ABORTED since URLRequest::BeforeRequestComplete
enforces not receiving cancelled requests with an assertion.
Our API requires the symmetric LoadStarten - LoadStopped
signals even on an ignored request so cancelling the request
and returning early would not be a solution, since it would
not emit any LoadStopped signal.
Change-Id: I1b13fe6520121805bcf420e810999c520c12bd5c
Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
Reviewed-by: Michael Bruning <michael.bruning@digia.com>
-rw-r--r-- | src/core/network_delegate_qt.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/core/network_delegate_qt.cpp b/src/core/network_delegate_qt.cpp index 8a79bbc8a..81ab4b6bc 100644 --- a/src/core/network_delegate_qt.cpp +++ b/src/core/network_delegate_qt.cpp @@ -136,9 +136,7 @@ void NetworkDelegateQt::CompleteURLRequestOnIOThread(net::URLRequest *request, error = net::OK; break; case WebContentsAdapterClient::IgnoreRequest: - error = net::OK; - // We can cancel the request here since we are on the IO thread. - request->Cancel(); + error = net::ERR_ABORTED; break; default: error = net::ERR_FAILED; |