Don't execute URLRequest callback for already canceled requests (issue #1685)
This commit is contained in:
parent
1999a3f237
commit
9ec03906a8
|
@ -122,7 +122,9 @@ class CefBeforeResourceLoadCallbackImpl : public CefRequestCallback {
|
|||
disconnector->Disconnect();
|
||||
request->RemoveUserData(UserDataKey());
|
||||
|
||||
callback.Run(allow ? net::OK : net::ERR_ABORTED);
|
||||
// Only execute the callback if the request has not been canceled.
|
||||
if (request->status().status() != net::URLRequestStatus::CANCELED)
|
||||
callback.Run(allow ? net::OK : net::ERR_ABORTED);
|
||||
}
|
||||
|
||||
static inline void* UserDataKey() {
|
||||
|
|
Loading…
Reference in New Issue