From 063056e1933c32956192580d130dd6f831778d68 Mon Sep 17 00:00:00 2001 From: Zorg Date: Sat, 18 Apr 2015 13:14:57 -0400 Subject: [PATCH] Ensure termListen is not deallocated before -[NSRunningApplication run] Related: Issue #441 I have no evidence that this is the cause of the issue, but from what we do know from the crash logs submitted, it looks like Sparkle crashes or errors on the main thread. It also looks like it might be from an object release rather than copying (which is done on a different thread) being the issue (see issue #417 also). I'm leaning towards this being an issue after the project was converted to ARC. --- Sparkle/Autoupdate/Autoupdate.m | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Sparkle/Autoupdate/Autoupdate.m b/Sparkle/Autoupdate/Autoupdate.m index 9d8e461a..81113375 100644 --- a/Sparkle/Autoupdate/Autoupdate.m +++ b/Sparkle/Autoupdate/Autoupdate.m @@ -204,9 +204,9 @@ int main(int __unused argc, const char __unused *argv[]) shouldShowUI:shouldShowUI selfPath:[[NSBundle mainBundle] bundlePath]]; - [termListen class]; [[NSApplication sharedApplication] run]; - + // Ensure termListen is not deallocated by ARC before caling -[NSApplication run] + [termListen class]; } return EXIT_SUCCESS;