WebKit Bugzilla
Attachment 345775 Details for
Bug 188015
: Crashing on some builds that don't have async NSSharingService API
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-188015-20180725130606.patch (text/plain), 2.24 KB, created by
Tim Horton
on 2018-07-25 13:06:07 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Tim Horton
Created:
2018-07-25 13:06:07 PDT
Size:
2.24 KB
patch
obsolete
>Index: Source/WebKit/ChangeLog >=================================================================== >--- Source/WebKit/ChangeLog (revision 234210) >+++ Source/WebKit/ChangeLog (working copy) >@@ -1,3 +1,14 @@ >+2018-07-25 Tim Horton <timothy_horton@apple.com> >+ >+ Crashing on some builds that don't have async NSSharingService API >+ https://bugs.webkit.org/show_bug.cgi?id=188015 >+ <rdar://problem/42593935> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * UIProcess/mac/ServicesController.mm: >+ (WebKit::hasCompatibleServicesForItems): >+ > 2018-07-25 Alex Christensen <achristensen@webkit.org> > > Use CompletionHandler for policy decisions >Index: Source/WebKit/UIProcess/mac/ServicesController.mm >=================================================================== >--- Source/WebKit/UIProcess/mac/ServicesController.mm (revision 234210) >+++ Source/WebKit/UIProcess/mac/ServicesController.mm (working copy) >@@ -71,15 +71,19 @@ static void hasCompatibleServicesForItem > NSSharingServiceMask servicesMask = NSSharingServiceMaskViewer | NSSharingServiceMaskEditor; > > #if __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400 >- dispatch_group_enter(group); >- [NSSharingService getSharingServicesForItems:items mask:servicesMask completion:BlockPtr<void(NSArray *)>::fromCallable([completionHandler = WTFMove(completionHandler), group](NSArray *services) { >- completionHandler(services.count); >- dispatch_group_leave(group); >- }).get()]; >+ if ([NSSharingService respondsToSelector:@selector(sharingServicesForItems:mask:completion:)]) { >+ dispatch_group_enter(group); >+ [NSSharingService getSharingServicesForItems:items mask:servicesMask completion:BlockPtr<void(NSArray *)>::fromCallable([completionHandler = WTFMove(completionHandler), group](NSArray *services) { >+ completionHandler(services.count); >+ dispatch_group_leave(group); >+ }).get()]; >+ return; >+ } > #else > UNUSED_PARAM(group); >- completionHandler([NSSharingService sharingServicesForItems:items mask:servicesMask].count); > #endif >+ >+ completionHandler([NSSharingService sharingServicesForItems:items mask:servicesMask].count); > } > > void ServicesController::refreshExistingServices(bool refreshImmediately)
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 188015
: 345775