diff --git a/SUUpdater.m b/SUUpdater.m index 5d441d7f..ca329b85 100644 --- a/SUUpdater.m +++ b/SUUpdater.m @@ -48,11 +48,17 @@ static NSString * const SUUpdaterDefaultsObservationContext = @"SUUpdaterDefault - (BOOL)isUpdateInProgress { BOOL result = NO; - NSConnection *connection = [NSConnection connectionWithRegisteredName:[NSString stringWithFormat:@"Sparkle %@", [[host bundle] bundleIdentifier]] host:nil]; - if (connection != nil) + @try + { + NSConnection *connection = [NSConnection connectionWithRegisteredName:[NSString stringWithFormat:@"Sparkle %@", [[host bundle] bundleIdentifier]] host:nil]; + if (connection != nil) + { + NSDistantObject *proxyBundle = [connection rootProxy]; + result = proxyBundle != nil; + } + } + @catch (NSException *exception) { - NSDistantObject *proxyBundle = [connection rootProxy]; - result = proxyBundle != nil; } return result;