mirror of
https://github.com/sparkle-project/Sparkle
synced 2026-11-28 05:14:34 +00:00
Make sure update directory != nil during cleanup
This commit is contained in:
1 parent
1ca233eadf
commit
5ad5598a19
1 file changed
+5
-3
@@ -607,9 +607,11 @@ static const NSTimeInterval SUDisplayProgressTimeDelay = 0.7;
|
||||
[self.agentConnection invalidate];
|
||||
self.agentConnection = nil;
|
||||
|
||||
NSError *theError = nil;
|
||||
if (![[[SUFileManager alloc] init] removeItemAtURL:[NSURL fileURLWithPath:self.updateDirectoryPath] error:&theError]) {
|
||||
SULog(@"Couldn't remove update folder: %@.", theError);
|
||||
if (self.updateDirectoryPath != nil) {
|
||||
NSError *theError = nil;
|
||||
if (![[[SUFileManager alloc] init] removeItemAtURL:[NSURL fileURLWithPath:self.updateDirectoryPath] error:&theError]) {
|
||||
SULog(@"Couldn't remove update folder: %@.", theError);
|
||||
}
|
||||
}
|
||||
|
||||
exit(status);
|
||||
|
||||
Reference in new issue
Block a user