Fixes Bug #321761: Update crashes below NSTask if /usr/bin/mdimport does not exist or is not executable

This commit is contained in:
Andy Matuschak committed 2009-02-11 14:54:55 -08:00
1 parent e35a1ca231
commit 05b75aa44c
1 file changed
+9 -1
+9 -1
View File
@@ -93,7 +93,15 @@
NSTask *mdimport = [[[NSTask alloc] init] autorelease];
[mdimport setLaunchPath:@"/usr/bin/mdimport"];
[mdimport setArguments:[NSArray arrayWithObject:[host bundlePath]]];
[mdimport launch];
@try
{
[mdimport launch];
}
@catch (NSException * launchException)
{
// No big deal.
NSLog(@"Sparkle Error: %@", [launchException description]);
}
}
+ (void)_finishInstallationWithResult:(BOOL)result host:(SUHost *)host error:(NSError *)error delegate:delegate