From cab224b0c61bbe3cd96847118971cdfef460a684 Mon Sep 17 00:00:00 2001 From: theevilbit Date: Wed, 17 Feb 2021 09:29:54 +0100 Subject: [PATCH] Update SMJClientUtility.m (__bridge CFURLRef)[NSURL URLWithString:bundlePath] returns NULL if the path contains a whitespace. The correct method to use is: (__bridge CFURLRef)[NSURL fileURLWithPath:bundlePath] --- SMJobKit/SMJClientUtility.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SMJobKit/SMJClientUtility.m b/SMJobKit/SMJClientUtility.m index 026a0d2..75724a5 100644 --- a/SMJobKit/SMJClientUtility.m +++ b/SMJobKit/SMJClientUtility.m @@ -20,7 +20,7 @@ + (NSString*) versionForBundlePath:(NSString*)bundlePath error:(NSError**)error SecStaticCodeRef codeRef; OSStatus result; - result = SecStaticCodeCreateWithPath((__bridge CFURLRef)[NSURL URLWithString:bundlePath], kSecCSDefaultFlags, &codeRef); + result = SecStaticCodeCreateWithPath((__bridge CFURLRef)[NSURL fileURLWithPath:bundlePath], kSecCSDefaultFlags, &codeRef); if (result != noErr) { if (result == errSecCSUnsigned)