Changeset 3794
- Timestamp:
- 07/18/08 17:42:24 (4 months ago)
- Files:
-
- trunk/Additions/NSNotificationAdditions.m (modified) (2 diffs)
- trunk/Chat Core/MVIRCChatConnection.m (modified) (3 diffs)
- trunk/Chat Core/MVSILCChatConnection.m (modified) (5 diffs)
- trunk/Chat Core/MVSILCFileTransfer.m (modified) (2 diffs)
- trunk/Chat Core/MVXMPPChatConnection.m (modified) (1 diff)
- trunk/Controllers/MVBuddyListController.m (modified) (1 diff)
- trunk/Controllers/MVConnectionsController.m (modified) (2 diffs)
- trunk/Controllers/MVCrashCatcher.m (modified) (1 diff)
- trunk/Frameworks/Acid/jabber/Jabber.m (modified) (2 diffs)
- trunk/Frameworks/Acid/jabber/JabberSocket.m (modified) (1 diff)
- trunk/Panels/JVDirectChatPanel.m (modified) (3 diffs)
- trunk/Views/MVTextView.m (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/Additions/NSNotificationAdditions.m
r3729 r3794 30 30 if( pthread_main_np() ) return [self postNotificationName:name object:object userInfo:userInfo]; 31 31 32 // The info dictionary is released in _postNotificationName. 32 33 NSMutableDictionary *info = [[NSMutableDictionary allocWithZone:nil] initWithCapacity:3]; 33 34 if( name ) [info setObject:name forKey:@"name"]; … … 45 46 [[self defaultCenter] postNotificationName:name object:object userInfo:userInfo]; 46 47 47 [info release]; 48 [info release]; // Balance the alloc in postNotificationOnMainThreadWithName. 48 49 } 49 50 @end trunk/Chat Core/MVIRCChatConnection.m
r3790 r3794 647 647 CFReadStreamSetProperty( [sock getCFReadStream], kCFStreamPropertySSLSettings, (CFDictionaryRef) settings ); 648 648 CFWriteStreamSetProperty( [sock getCFWriteStream], kCFStreamPropertySSLSettings, (CFDictionaryRef) settings ); 649 650 [settings release]; 649 651 } 650 652 … … 2043 2045 MVAssertCorrectThreadRequired( _connectionThread ); 2044 2046 2047 // The info dictionary is released in _handleCTCP:. 2045 2048 NSMutableDictionary *info = [[NSMutableDictionary allocWithZone:nil] initWithCapacity:4]; 2046 2049 if( data ) [info setObject:data forKey:@"data"]; … … 2063 2066 2064 2067 if( [sender isLocalUser] ) { 2068 // The room is released in _handle366WithParameters. 2065 2069 if( ! room ) { 2066 2070 room = [[MVIRCChatRoom allocWithZone:nil] initWithName:name andConnection:self]; trunk/Chat Core/MVSILCChatConnection.m
r3763 r3794 56 56 [[NSNotificationCenter defaultCenter] postNotificationOnMainThreadWithName:MVChatRoomBannedUsersSyncedNotification object:room userInfo:nil]; 57 57 58 [room release]; 58 [room release]; // Balance the retain in silc_command_reply (case SILC_COMMAND_JOIN). 59 59 } 60 60 … … 629 629 /* SilcUInt32 user_limit = */ va_arg( list, SilcUInt32 ); 630 630 631 // The room is released in silc_channel_get_clients_per_list_callback. 631 632 MVSILCChatRoom *room = (MVSILCChatRoom *)[self joinedChatRoomWithChannel:channel]; 632 633 if( ! room ) { … … 728 729 void *completionContext = SILC_32_TO_PTR( [(NSNumber *)[dict objectForKey:@"context"] unsignedIntValue] ); 729 730 730 [dict release]; // was retained earlier in silc_get_auth_method731 dict = nil;732 733 731 switch( auth_method ) { 734 732 case SILC_AUTH_NONE: … … 747 745 break; 748 746 } 747 748 [dict release]; // Balance the alloc in silc_get_auth_method. 749 749 } 750 750 751 751 static void silc_get_auth_method( SilcClient client, SilcClientConnection conn, char *hostname, SilcUInt16 port, SilcGetAuthMeth completion, void *context ) { 752 // The dictionary is released in silc_get_auth_method_callback. 752 753 NSDictionary *dict = [[NSDictionary allocWithZone:nil] initWithObjectsAndKeys:[NSNumber numberWithUnsignedInt:SILC_PTR_TO_32( completion )], @"completion", [NSNumber numberWithUnsignedInt:SILC_PTR_TO_32( context )], @"context", nil]; 753 754 silc_client_request_authentication_method( client, conn, silc_get_auth_method_callback, dict ); … … 835 836 836 837 [[NSNotificationCenter defaultCenter] postNotificationOnMainThreadWithName:MVChatConnectionNeedPublicKeyVerificationNotification object:self userInfo:dict]; 838 839 [dict release]; 837 840 } 838 841 trunk/Chat Core/MVSILCFileTransfer.m
r3420 r3794 118 118 if( error != SILC_CLIENT_FILE_OK ) { 119 119 [transfer _silcPostError:error]; 120 [transfer release]; 120 121 SilcUnlock( [[user connection] _silcClient] ); 121 122 return nil; … … 128 129 } else return nil; 129 130 130 return transfer;131 return [transfer autorelease]; 131 132 } 132 133 trunk/Chat Core/MVXMPPChatConnection.m
r3722 r3794 388 388 if ([[presence getAttribute:@"type"] isCaseInsensitiveEqualToString:@"error"]) { 389 389 [self _removeJoinedRoom:room]; 390 [room release]; 390 [room release]; // balance the alloc or retain in joinChatRoomNamed: 391 391 // handle error... 392 392 return; trunk/Controllers/MVBuddyListController.m
r3607 r3794 331 331 332 332 [buddy addWatchRule:rule]; 333 [rule release]; 333 334 334 335 [self addBuddy:buddy]; 336 [buddy release]; 337 335 338 [self save]; 336 339 trunk/Controllers/MVConnectionsController.m
r3763 r3794 37 37 #pragma mark - 38 38 39 @interface NSDisclosureButtonCell 39 @interface NSDisclosureButtonCell : NSCell 40 40 + (id) alloc; 41 41 - (id) initWithCell:(NSCell *) cell; … … 214 214 [toolbar setAutosavesConfiguration:YES]; 215 215 [[self window] setToolbar:toolbar]; 216 217 [showDetails setCell:[[NSDisclosureButtonCell alloc] initWithCell:[showDetails cell]]]; 216 217 NSDisclosureButtonCell *cell = [[NSDisclosureButtonCell alloc] initWithCell:[showDetails cell]]; 218 [showDetails setCell:cell]; 219 [cell release]; 218 220 219 221 [self setWindowFrameAutosaveName:@"Connections"]; trunk/Controllers/MVCrashCatcher.m
r3763 r3794 6 6 if( [[NSBundle bundleWithIdentifier:@"com.unsanity.smartcrashreports"] isLoaded] ) 7 7 return; // user has Unsanity Smart Crash Reports installed, don't use our own reporter 8 [[MVCrashCatcher alloc] init]; 8 [[MVCrashCatcher alloc] init]; // Released when the window is closed. 9 9 } 10 10 trunk/Frameworks/Acid/jabber/Jabber.m
r3640 r3794 43 43 +(void) load 44 44 { 45 [[NSAutoreleasePool alloc] init];45 NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; 46 46 47 47 // Setup QNames … … 62 62 [XMLElementStream registerElementFactory:[JabberMessage class]]; 63 63 [XMLElementStream registerElementFactory:[JabberSubscriptionRequest class]]; 64 65 [pool drain]; 64 66 } 65 67 trunk/Frameworks/Acid/jabber/JabberSocket.m
r3764 r3794 111 111 CFReadStreamSetProperty( [sock getCFReadStream], kCFStreamPropertySSLSettings, (CFDictionaryRef) settings ); 112 112 CFWriteStreamSetProperty( [sock getCFWriteStream], kCFStreamPropertySSLSettings, (CFDictionaryRef) settings ); 113 114 [settings release]; 113 115 } 114 116 trunk/Panels/JVDirectChatPanel.m
r3790 r3794 231 231 [[self transcript] setFilePath:logs]; 232 232 [[self transcript] setSource:source]; 233 [source release];234 233 [[self transcript] setAutomaticallyWritesChangesToFile:YES]; 235 234 } 235 236 [source release]; 236 237 237 238 [[self transcript] setElementLimit:0]; // start with zero limit … … 841 842 if( ! [messageString length] && [cmessage ignoreStatus] == JVNotIgnored ) { // plugins decided to excluded this message, decrease the new message counts 842 843 _newMessageCount--; 844 [cmessage release]; 843 845 return; 844 846 } … … 1383 1385 1384 1386 [toolbarItem setToolTip:NSLocalizedString( @"Text Encoding Options", "encoding menu toolbar item tooltip" )]; 1385 [toolbarItem setView:button];1386 1387 [toolbarItem setMinSize:NSMakeSize( 60., 24. )]; 1387 1388 [toolbarItem setMaxSize:NSMakeSize( 60., 32. )]; 1389 1390 [toolbarItem setView:button]; 1391 [button release]; 1388 1392 1389 1393 NSMenuItem *menuItem = [[[NSMenuItem alloc] initWithTitle:NSLocalizedString( @"Encoding", "encoding menu toolbar item" ) action:NULL keyEquivalent:@""] autorelease]; trunk/Views/MVTextView.m
r3770 r3794 37 37 38 38 if( ! [self isEditable] ) { 39 [newArray release]; 39 40 [super interpretKeyEvents:eventArray]; 40 41 return;
