adium/adium

Parents 3a28d740babe
Children 2088de30d4fe
Keep the NSConnection AIAdium creates around, so the static analyzer can be happy about it.
--- a/Source/AIAdium.h Sun Jan 29 21:00:22 2012 +0100
+++ b/Source/AIAdium.h Sun Jan 29 21:24:57 2012 +0100
@@ -62,6 +62,7 @@
BOOL completedApplicationLoad;
NSString *advancedPrefsName;
BOOL isQuitting;
+ NSConnection *connection;
}
- (IBAction)showAboutBox:(id)sender;
--- a/Source/AIAdium.m Sun Jan 29 21:00:22 2012 +0100
+++ b/Source/AIAdium.m Sun Jan 29 21:24:57 2012 +0100
@@ -262,7 +262,7 @@
object:nil];
//Broadcast our presence
- NSConnection *connection = [[NSConnection alloc] init];
+ connection = [[NSConnection alloc] init];
[connection setRootObject:self];
[connection registerName:@"com.adiumX.adiumX"];
@@ -343,6 +343,8 @@
{
//Take no action if we didn't complete the application load
if (!completedApplicationLoad) return;
+
+ [connection release]; connection = nil;
isQuitting = YES;