Changeset 272799 in webkit


Ignore:
Timestamp:
Feb 12, 2021, 12:25:53 PM (4 years ago)
Author:
dino@apple.com
Message:

Unexpected ASSERT when touch events are dispatched on the main thread
https://bugs.webkit.org/show_bug.cgi?id=221832
<rdar://problem/74283856>

Reviewed by Sam Weinig.

The change in r272558 causes an ASSERT when running on iOS debug
builds. The touch event CompletionHandlers are created on the EventDispatcher
thread, but serviced on the main thread. We now need to state that this
is ok as we create the CompletionHandler.

This is covered by tests, but the EWS bots don't run iOS tests in
debug mode, and the internal bots hadn't caught up yet!

  • Platform/IPC/HandleMessage.h:

(IPC::handleMessageAsync): Pass a CompletionHandlerCallThread into the constructor.

Location:
trunk/Source/WebKit
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit/ChangeLog

    r272796 r272799  
     12021-02-12  Dean Jackson  <dino@apple.com>
     2
     3        Unexpected ASSERT when touch events are dispatched on the main thread
     4        https://bugs.webkit.org/show_bug.cgi?id=221832
     5        <rdar://problem/74283856>
     6
     7        Reviewed by Sam Weinig.
     8
     9        The change in r272558 causes an ASSERT when running on iOS debug
     10        builds. The touch event CompletionHandlers are created on the EventDispatcher
     11        thread, but serviced on the main thread. We now need to state that this
     12        is ok as we create the CompletionHandler.
     13
     14        This is covered by tests, but the EWS bots don't run iOS tests in
     15        debug mode, and the internal bots hadn't caught up yet!
     16
     17        * Platform/IPC/HandleMessage.h:
     18        (IPC::handleMessageAsync): Pass a CompletionHandlerCallThread into the constructor.
     19
    1202021-02-12  Brent Fulgham  <bfulgham@apple.com>
    221
  • trunk/Source/WebKit/Platform/IPC/HandleMessage.h

    r272592 r272799  
    182182    }
    183183
    184     typename T::AsyncReply completionHandler = [listenerID = *listenerID, connection = makeRef(connection)] (auto&&... args) mutable {
     184    typename T::AsyncReply completionHandler = { [listenerID = *listenerID, connection = makeRef(connection)] (auto&&... args) mutable {
    185185        auto encoder = makeUnique<Encoder>(T::asyncMessageReplyName(), listenerID);
    186186        T::send(WTFMove(encoder), WTFMove(connection), args...);
    187     };
     187    }, CompletionHandlerCallThread::MainThread };
    188188    callMemberFunction(WTFMove(*arguments), WTFMove(completionHandler), object, function);
    189189}
Note: See TracChangeset for help on using the changeset viewer.