mirror of
https://github.com/sparkle-project/Sparkle
synced 2026-11-26 04:57:54 +00:00
Extra follow-up for prev.rev.
This commit is contained in:
1 parent
92d7b9f68f
commit
46c22e2bbf
1 file changed
+5
-8
@@ -388,19 +388,16 @@ NSArray *SUGetAllDevMateURLHosts(void)
|
||||
#endif
|
||||
|
||||
// Only the paranoid survive: if there's already a stray copy of relaunch there, we would have problems.
|
||||
if( [SUUpdater shouldUseXPCInstaller] )
|
||||
BOOL copiedRelaunchTool = NO;
|
||||
if (SUShouldUseXPCInstaller())
|
||||
{
|
||||
[SUXPCInstaller copyPathWithAuthentication:relaunchPathToCopy overPath:targetPath temporaryName:nil completionHandler:^(NSError *xpcError) {
|
||||
if (xpcError != nil)
|
||||
NSLog(@"Error during asynchronous XPC call to copyPath: %@", xpcError);
|
||||
[self finishRelaunchAfterSuccessfulCopying:(xpcError == nil) fromPath:relaunchPathToCopy toPath:targetPath relaunch:relaunch];
|
||||
}];
|
||||
copiedRelaunchTool = [SUXPCInstaller copyPathWithAuthentication:relaunchPathToCopy overPath:targetPath temporaryName:nil error:&error];
|
||||
}
|
||||
else
|
||||
{
|
||||
BOOL copiedRelaunchTool = [SUPlainInstaller copyPathWithAuthentication: relaunchPathToCopy overPath: targetPath temporaryName: nil error: &error];
|
||||
[self finishRelaunchAfterSuccessfulCopying:copiedRelaunchTool fromPath:relaunchPathToCopy toPath:targetPath relaunch:relaunch];
|
||||
copiedRelaunchTool = [SUPlainInstaller copyPathWithAuthentication:relaunchPathToCopy overPath:targetPath temporaryName:nil error:&error];
|
||||
}
|
||||
[self finishRelaunchAfterSuccessfulCopying:copiedRelaunchTool fromPath:relaunchPathToCopy toPath:targetPath relaunch:relaunch];
|
||||
}
|
||||
|
||||
- (void)finishRelaunchAfterSuccessfulCopying:(BOOL)copiedRelaunchTool fromPath:(NSString *)relaunchPathToCopy toPath:(NSString *)targetPath relaunch:(BOOL)relaunch
|
||||
|
||||
Reference in new issue
Block a user