Bug 126021

Summary: Different and incorrect flags are passed to sendSync when accessibility is enabled, SpinRunLoopWhileWaitingForReply
Product: WebKit Reporter: Alexey Proskuryakov <ap>
Component: AccessibilityAssignee: mitz
Severity: Normal CC: andersca, cfleizach, darin, mitz, sam, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on: 127411, 127429    
Bug Blocks:    
Description Flags
Get rid of SpinRunLoopWhileWaitingForReply darin: review+

Description Alexey Proskuryakov 2013-12-19 15:06:09 PST
In WebKit2, we have multiple places where sendSync flags depend on whether accessibility is enabled.

    unsigned syncSendFlags = (WebCore::AXObjectCache::accessibilityEnabled()) ? CoreIPC::SpinRunLoopWhileWaitingForReply : 0;
    WebProcess::shared().parentProcessConnection()->sendSync(Messages::WebPageProxy::RunJavaScriptAlert(webFrame->frameID(), alertText), Messages::WebPageProxy::RunJavaScriptAlert::Reply(), m_page->pageID(), CoreIPC::Connection::NoTimeout, syncSendFlags);

It is unfortunate to have such differences, because we get to support two runtime behaviors instead of one. I think that we should either make SpinRunLoopWhileWaitingForReply unconditional, or stop passing SpinRunLoopWhileWaitingForReply, and find different fixes for bugs it was needed for.

Bug 126014 is one case where SpinRunLoopWhileWaitingForReply was found to cause significant trouble.
Comment 1 Alexey Proskuryakov 2013-12-19 15:32:09 PST
See also: bug 123828.
Comment 2 Radar WebKit Bug Importer 2013-12-19 15:32:21 PST
Comment 3 Alexey Proskuryakov 2014-01-26 18:00:30 PST
Removing "possibly" from the title, as it's certainly incorrect given the test crashes seen in blocking bugs.

Now that accessibility gets disabled after each test, this should affect testing, but it may cause instability in real life.
Comment 4 mitz 2015-12-20 08:23:54 PST
Created attachment 267719 [details]
Get rid of SpinRunLoopWhileWaitingForReply
Comment 5 mitz 2015-12-21 07:17:37 PST
Committed <http://trac.webkit.org/r194330>.