WebKit Bugzilla
Attachment 343058 Details for
Bug 186805
: WebCoreNSURLSessionDataTaskClient::redirectReceived() calls WebCore on non-main thread
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-186805-20180619084334.patch (text/plain), 2.12 KB, created by
Chris Dumez
on 2018-06-19 08:43:34 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Chris Dumez
Created:
2018-06-19 08:43:34 PDT
Size:
2.12 KB
patch
obsolete
>Subversion Revision: 232959 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index 2b36c20af17dc041602c3e5c65268615c6cb2b16..4f6aa8e38fdbac22ac612a969bc6959eec926fe6 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,18 @@ >+2018-06-19 Chris Dumez <cdumez@apple.com> >+ >+ WebCoreNSURLSessionDataTaskClient::redirectReceived() calls WebCore on non-main thread >+ https://bugs.webkit.org/show_bug.cgi?id=186805 >+ <rdar://problem/36960714> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Make sure WebCoreNSURLSessionDataTaskClient::redirectReceived() dispatches to the main >+ thread before calling its completion handler. Otherwise, we end up calling into WebCore >+ on a NSOperationQueue background thread and we crash. >+ >+ * platform/network/cocoa/WebCoreNSURLSession.mm: >+ (WebCore::WebCoreNSURLSessionDataTaskClient::redirectReceived): >+ > 2018-06-19 David Kilzer <ddkilzer@apple.com> > > Add logging when splashboardd enables WebThread >diff --git a/Source/WebCore/platform/network/cocoa/WebCoreNSURLSession.mm b/Source/WebCore/platform/network/cocoa/WebCoreNSURLSession.mm >index 37cbb3249e344360c177c65af45714e3658dc31c..517c96ac49517b2226cf5e86bd97a2c4341736e3 100644 >--- a/Source/WebCore/platform/network/cocoa/WebCoreNSURLSession.mm >+++ b/Source/WebCore/platform/network/cocoa/WebCoreNSURLSession.mm >@@ -418,9 +418,10 @@ void WebCoreNSURLSessionDataTaskClient::redirectReceived(PlatformMediaResource& > if (!m_task) > return; > >- [m_task resource:resource receivedRedirect:response request:WTFMove(request) completionHandler: [completionHandler = WTFMove(completionHandler)] (auto&& request) { >- ASSERT(isMainThread()); >- completionHandler(WTFMove(request)); >+ [m_task resource:resource receivedRedirect:response request:WTFMove(request) completionHandler: [completionHandler = WTFMove(completionHandler)] (auto&& request) mutable { >+ callOnMainThread([request = request.isolatedCopy(), completionHandler = WTFMove(completionHandler)] () mutable { >+ completionHandler(WTFMove(request)); >+ }); > }]; > } >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 186805
: 343058