Sandbox Broker: Fixed a potential reference crash
The code which looked up Sandbox handles for a given path had a bug where it would re-add the handle to the in-memory cache storage even if it already had just retrieved the current handle from the cache. I hope this will fix the crashes which have been plaguing people adding a lot of files to the playlist all at once from a single folder. Signed-off-by: Christopher Snowhill <kode54@gmail.com>xcode15
parent
d8f0a19524
commit
9c67eb78fc
|
@ -435,16 +435,12 @@ static inline void dispatch_sync_reentrant(dispatch_queue_t queue, dispatch_bloc
|
|||
|
||||
if(!_entry) {
|
||||
_entry = [self recursivePathTest:folderUrl];
|
||||
if(_entry)
|
||||
[self->storage addObject:_entry];
|
||||
}
|
||||
|
||||
if(_entry) {
|
||||
[self->storage addObject:_entry];
|
||||
|
||||
if(_entry.secureUrl) {
|
||||
[_entry.secureUrl startAccessingSecurityScopedResource];
|
||||
}
|
||||
} else {
|
||||
_entry = NULL;
|
||||
if(_entry && _entry.secureUrl) {
|
||||
[_entry.secureUrl startAccessingSecurityScopedResource];
|
||||
}
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in New Issue