⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 245748 in webkit


Ignore:
Timestamp:
May 24, 2019, 11:26:45 AM (7 years ago)
Author:
youenn@apple.com
Message:

Make sure completion handler is always called in SWServer::startSuspension
https://bugs.webkit.org/show_bug.cgi?id=198215

Reviewed by Alex Christensen.

  • workers/service/server/SWServer.cpp:

(WebCore::SWServer::startSuspension):
Make sure completion handler is called in case of no registration store.

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r245746 r245748  
     12019-05-24  Youenn Fablet  <youenn@apple.com>
     2
     3        Make sure completion handler is always called in SWServer::startSuspension
     4        https://bugs.webkit.org/show_bug.cgi?id=198215
     5
     6        Reviewed by Alex Christensen.
     7
     8        * workers/service/server/SWServer.cpp:
     9        (WebCore::SWServer::startSuspension):
     10        Make sure completion handler is called in case of no registration store.
     11
    1122019-05-24  Ryosuke Niwa  <rniwa@webkit.org>
    213
  • trunk/Source/WebCore/workers/service/server/SWServer.cpp

    r245299 r245748  
    221221void SWServer::startSuspension(CompletionHandler<void()>&& completionHandler)
    222222{
    223     if (m_registrationStore)
    224         m_registrationStore->startSuspension(WTFMove(completionHandler));
     223    if (!m_registrationStore) {
     224        completionHandler();
     225        return;
     226    }
     227    m_registrationStore->startSuspension(WTFMove(completionHandler));
    225228}
    226229
Note: See TracChangeset for help on using the changeset viewer.