fix: Resolve bookmarks without mounting network drives (#24708)

This commit is contained in:
Charlie Hess 2020-08-20 18:01:08 -04:00 committed by GitHub
parent d9a1c453ab
commit 42409d860b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -32,12 +32,13 @@ base::RepeatingCallback<void()> App::StartAccessingSecurityScopedResource(
// Create bookmarkUrl from NSData. // Create bookmarkUrl from NSData.
BOOL isStale = false; BOOL isStale = false;
NSError* error = nil; NSError* error = nil;
NSURL* bookmarkUrl = NSURL* bookmarkUrl = [NSURL
[NSURL URLByResolvingBookmarkData:bookmarkData URLByResolvingBookmarkData:bookmarkData
options:NSURLBookmarkResolutionWithSecurityScope options:NSURLBookmarkResolutionWithSecurityScope |
relativeToURL:nil NSURLBookmarkResolutionWithoutMounting
bookmarkDataIsStale:&isStale relativeToURL:nil
error:&error]; bookmarkDataIsStale:&isStale
error:&error];
if (error != nil) { if (error != nil) {
NSString* err = NSString* err =