Skip to content

Commit

Permalink
Fixes sparkle-project#221: char *oldDestinationString
Browse files Browse the repository at this point in the history
  • Loading branch information
andymatuschak committed Nov 16, 2012
1 parent 860739f commit f662210
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion SUPipedUnarchiver.m
Expand Up @@ -51,6 +51,7 @@ - (void)extractArchivePipingDataToCommand:(NSString *)command

NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
FILE *fp = NULL, *cmdFP = NULL;
char *oldDestinationString = NULL;

SULog(@"Extracting %@ using '%@'",archivePath,command);

Expand All @@ -67,7 +68,7 @@ - (void)extractArchivePipingDataToCommand:(NSString *)command
fp = fopen([archivePath fileSystemRepresentation], "r");
if (!fp) goto reportError;

char *oldDestinationString = getenv("DESTINATION");
oldDestinationString = getenv("DESTINATION");
setenv("DESTINATION", [[archivePath stringByDeletingLastPathComponent] fileSystemRepresentation], 1);
cmdFP = popen([command fileSystemRepresentation], "w");
size_t written;
Expand Down

0 comments on commit f662210

Please sign in to comment.