Title: [290128] trunk/Source/WebKit
- Revision
- 290128
- Author
- [email protected]
- Date
- 2022-02-18 08:41:41 -0800 (Fri, 18 Feb 2022)
Log Message
AX: isAXAuthenticatedCallback must be handled on the main runloop
https://bugs.webkit.org/show_bug.cgi?id=236789
Reviewed by Chris Fleizach.
isAXAuthenticatedCallback in WebProcessCocoa.mm performs IPC to the UI process
to determine if the given auditToken is valid. This causes a crash with isolated
tree mode enabled as IPC must be performed on the main thread / runloop.
This patch changes this function to dispatch to the main runloop.
* WebProcess/cocoa/WebProcessCocoa.mm:
(WebKit::isAXAuthenticatedCallback):
Modified Paths
Diff
Modified: trunk/Source/WebKit/ChangeLog (290127 => 290128)
--- trunk/Source/WebKit/ChangeLog 2022-02-18 16:30:58 UTC (rev 290127)
+++ trunk/Source/WebKit/ChangeLog 2022-02-18 16:41:41 UTC (rev 290128)
@@ -1,3 +1,19 @@
+2022-02-18 Tyler Wilcock <[email protected]>
+
+ AX: isAXAuthenticatedCallback must be handled on the main runloop
+ https://bugs.webkit.org/show_bug.cgi?id=236789
+
+ Reviewed by Chris Fleizach.
+
+ isAXAuthenticatedCallback in WebProcessCocoa.mm performs IPC to the UI process
+ to determine if the given auditToken is valid. This causes a crash with isolated
+ tree mode enabled as IPC must be performed on the main thread / runloop.
+
+ This patch changes this function to dispatch to the main runloop.
+
+ * WebProcess/cocoa/WebProcessCocoa.mm:
+ (WebKit::isAXAuthenticatedCallback):
+
2022-02-18 Saam Barati <[email protected]>
Add LC_SOURCE_VERSION to compile targets
Modified: trunk/Source/WebKit/WebProcess/cocoa/WebProcessCocoa.mm (290127 => 290128)
--- trunk/Source/WebKit/WebProcess/cocoa/WebProcessCocoa.mm 2022-02-18 16:30:58 UTC (rev 290127)
+++ trunk/Source/WebKit/WebProcess/cocoa/WebProcessCocoa.mm 2022-02-18 16:41:41 UTC (rev 290128)
@@ -224,7 +224,10 @@
static Boolean isAXAuthenticatedCallback(audit_token_t auditToken)
{
bool authenticated = false;
- WebProcess::singleton().parentProcessConnection()->sendSync(Messages::WebProcessProxy::IsAXAuthenticated(auditToken), Messages::WebProcessProxy::IsAXAuthenticated::Reply(authenticated), 0);
+ // IPC must be done on the main runloop, so dispatch it to avoid crashes when the secondary AX thread handles this callback.
+ callOnMainRunLoopAndWait([&authenticated, auditToken] {
+ WebProcess::singleton().parentProcessConnection()->sendSync(Messages::WebProcessProxy::IsAXAuthenticated(auditToken), Messages::WebProcessProxy::IsAXAuthenticated::Reply(authenticated), 0);
+ });
return authenticated;
}
#endif
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes