Merge pull request #1978 from dreampiggy/fix_CFRelease_crash

Fix CFRelease on NULL if CGImageSourceRef create failed
This commit is contained in:
Bogdan Poplauschi 2017-08-02 14:45:27 +03:00 committed by GitHub
commit ff3b4ac9fd
1 changed files with 3 additions and 1 deletions

View File

@ -376,7 +376,9 @@ didReceiveResponse:(NSURLResponse *)response
}
}
CFRelease(imageSource);
if (imageSource) {
CFRelease(imageSource);
}
}
for (SDWebImageDownloaderProgressBlock progressBlock in [self callbacksForKey:kProgressCallbackKey]) {