Permalink
Browse files

Making sure to initialize all Security types

  • Loading branch information...
1 parent 21f9546 commit 22b65a3095cfd527a334450a7dfe6434ad9741b7 @andymatuschak andymatuschak committed Jul 6, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 SUCodeSigningVerifier.m
View
@@ -72,11 +72,11 @@ + (BOOL)hostApplicationIsCodeSigned
if (SecCodeCopySelf == NULL) return NO;
OSStatus result;
- SecCodeRef hostCode;
+ SecCodeRef hostCode = NULL;
result = SecCodeCopySelf(kSecCSDefaultFlags, &hostCode);
if (result != 0) return NO;
- SecRequirementRef requirement;
+ SecRequirementRef requirement = NULL;
result = SecCodeCopyDesignatedRequirement(hostCode, kSecCSDefaultFlags, &requirement);
if (hostCode) CFRelease(hostCode);
if (requirement) CFRelease(requirement);

0 comments on commit 22b65a3

Please sign in to comment.