From 339b3359c468b59b8bc254269b8fc0cba7b5c9cb Mon Sep 17 00:00:00 2001 From: ritsuka Date: Thu, 19 Mar 2015 16:28:09 +0000 Subject: [PATCH] MacGui: fix the error variable in canScan:error: , it was dereferenced one time too many. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@7006 b64f7644-9d1e-0410-96f1-a4d463321fa5 --- macosx/HBCore.h | 2 +- macosx/HBCore.m | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/macosx/HBCore.h b/macosx/HBCore.h index 03d05ba9e..083ac5d51 100644 --- a/macosx/HBCore.h +++ b/macosx/HBCore.h @@ -84,7 +84,7 @@ typedef void (^HBCoreCompletionHandler)(BOOL success); * * @return YES is the file at URL is scannable. */ -- (BOOL)canScan:(NSURL *)url error:(NSError **)error; +- (BOOL)canScan:(NSURL *)url error:(NSError * __autoreleasing *)error; /** * Initiates an asynchronous scan operation and returns immediately. diff --git a/macosx/HBCore.m b/macosx/HBCore.m index bc37a128e..13590aa8a 100644 --- a/macosx/HBCore.m +++ b/macosx/HBCore.m @@ -131,10 +131,10 @@ static void hb_error_handler(const char *errmsg) #pragma mark - Scan -- (BOOL)canScan:(NSURL *)url error:(NSError **)error +- (BOOL)canScan:(NSURL *)url error:(NSError * __autoreleasing *)error { if (![[NSFileManager defaultManager] fileExistsAtPath:url.path]) { - if (*error) { + if (error) { *error = [NSError errorWithDomain:@"HBErrorDomain" code:100 userInfo:@{ NSLocalizedDescriptionKey: @"Unable to find the file at the specified URL" }]; -- 2.40.0