From 3fddd63329ad9ed2ea13a1520ca01752f85375f6 Mon Sep 17 00:00:00 2001 From: Marc Liyanage Date: Tue, 12 Mar 2013 22:57:39 -0700 Subject: [PATCH] Reorder variable initialization to satisfy stricter compiler. --- SUPipedUnarchiver.m | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/SUPipedUnarchiver.m b/SUPipedUnarchiver.m index 08246647..cfd7a995 100644 --- a/SUPipedUnarchiver.m +++ b/SUPipedUnarchiver.m @@ -60,6 +60,8 @@ #else NSNumber *fs = [[[NSFileManager defaultManager] attributesOfItemAtPath:archivePath error:nil] objectForKey:NSFileSize]; #endif + char *oldDestinationString = getenv("DESTINATION"); + if (fs == nil) goto reportError; // Thank you, Allan Odgaard! @@ -67,7 +69,6 @@ fp = fopen([archivePath fileSystemRepresentation], "r"); if (!fp) goto reportError; - char *oldDestinationString = getenv("DESTINATION"); setenv("DESTINATION", [[archivePath stringByDeletingLastPathComponent] fileSystemRepresentation], 1); cmdFP = popen([command fileSystemRepresentation], "w"); size_t written;