From: timothy_horton@apple.com Date: Fri, 29 Aug 2014 21:32:40 +0000 (+0000) Subject: More occasional crashes in ServicesController::resfreshExistingServices X-Git-Url: https://git.webkit.org/?p=WebKit-https.git;a=commitdiff_plain;h=cc6f26ac88c127a7dffb012680e2b2c141e9cff7 More occasional crashes in ServicesController::resfreshExistingServices https://bugs.webkit.org/show_bug.cgi?id=136387 Reviewed by Dan Bernstein. * UIProcess/mac/ServicesController.mm: (WebKit::ServicesController::ServicesController): Speculative fix; if this block is called synchronously, we'll end up calling back into ::shared() before the NeverDestroyed is initialized, ending up with two ServicesControllers. git-svn-id: https://svn.webkit.org/repository/webkit/trunk@173119 268f45cc-cd09-0410-ab3c-d52691b4dbfc --- diff --git a/Source/WebKit2/ChangeLog b/Source/WebKit2/ChangeLog index 1a8047e20ee2..4d065c847544 100644 --- a/Source/WebKit2/ChangeLog +++ b/Source/WebKit2/ChangeLog @@ -1,3 +1,17 @@ +2014-08-29 Tim Horton + + More occasional crashes in ServicesController::resfreshExistingServices + https://bugs.webkit.org/show_bug.cgi?id=136387 + + + Reviewed by Dan Bernstein. + + * UIProcess/mac/ServicesController.mm: + (WebKit::ServicesController::ServicesController): + Speculative fix; if this block is called synchronously, we'll end up + calling back into ::shared() before the NeverDestroyed is initialized, + ending up with two ServicesControllers. + 2014-08-29 Alexey Proskuryakov WebPageProxy::close() is a no-op for terminated processes diff --git a/Source/WebKit2/UIProcess/mac/ServicesController.mm b/Source/WebKit2/UIProcess/mac/ServicesController.mm index 39859aab62e7..7f1a02b4ad2c 100644 --- a/Source/WebKit2/UIProcess/mac/ServicesController.mm +++ b/Source/WebKit2/UIProcess/mac/ServicesController.mm @@ -98,9 +98,9 @@ ServicesController::ServicesController() refreshExistingServices(); #ifdef __LP64__ - auto refreshCallback = [](NSArray *, NSError *) { + auto refreshCallback = [this](NSArray *, NSError *) { // We coalese refreshes from the notification callbacks because they can come in small batches. - ServicesController::shared().refreshExistingServices(false); + refreshExistingServices(false); }; auto extensionAttributes = @{ @"NSExtensionPointName" : @"com.apple.services" };