From 90190dcef67fc1ad6a28f7986e5cd3471ecb3b4d Mon Sep 17 00:00:00 2001 From: Wolfgang Sourdeau Date: Tue, 24 Mar 2009 16:34:03 +0000 Subject: [PATCH] Monotone-Parent: 011dcdb832dcd44414e6e9546d62de0737fbdcd6 Monotone-Revision: 077cf05982d8b328c0c4db80c174a594d7195243 Monotone-Author: wsourdeau@inverse.ca Monotone-Date: 2009-03-24T16:34:03 Monotone-Branch: ca.inverse.sogo --- ChangeLog | 4 ++++ UI/Scheduler/UIxComponentEditor.m | 15 +++++++-------- 2 files changed, 11 insertions(+), 8 deletions(-) diff --git a/ChangeLog b/ChangeLog index bd1c2c991..842e1cd04 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2009-03-24 Wolfgang Sourdeau + * UI/Scheduler/UIxComponentEditor.m ([UIxComponentEditor + -_loadAttendees]): make use of autoreleased strings to avoid a leak. + ([UIxComponentEditor -dealloc]): release componentCalendar. + * SoObjects/SOGo/SOGoUser.m ([SOGoUser -_prepareDefaultMailAccounts]): return an autoreleased array to avoid a leak. diff --git a/UI/Scheduler/UIxComponentEditor.m b/UI/Scheduler/UIxComponentEditor.m index a8375cfe0..ea2cb6077 100644 --- a/UI/Scheduler/UIxComponentEditor.m +++ b/UI/Scheduler/UIxComponentEditor.m @@ -104,6 +104,7 @@ iRANGE(2); dateFormat = [datePicker dateFormat]; component = nil; + componentCalendar = nil; [self setPrivacy: @"PUBLIC"]; [self setIsCycleEndNever]; componentOwner = @""; @@ -168,6 +169,7 @@ iRANGE(2); [range2 release]; [component release]; + [componentCalendar release]; [super dealloc]; } @@ -180,10 +182,10 @@ iRANGE(2); NSString *uid; LDAPUserManager *um; - names = [NSMutableString new]; - uids = [NSMutableString new]; - emails = [NSMutableString new]; - states = [NSMutableString new]; + names = [NSMutableString string]; + uids = [NSMutableString string]; + emails = [NSMutableString string]; + states = [NSMutableString string]; um = [LDAPUserManager sharedUserManager]; attendees = [[component attendees] objectEnumerator]; @@ -212,9 +214,6 @@ iRANGE(2); [emails substringToIndex: [emails length] - 1]); ASSIGN (attendeesStates, [states substringToIndex: [states length] - 1]); } - - [names release]; - [emails release]; } - (void) _loadCategories @@ -397,7 +396,7 @@ iRANGE(2); [self _loadAttendees]; [self _loadRRules]; - [componentCalendar release]; + [componentCalendar release]; componentCalendar = [co container]; if ([componentCalendar isKindOfClass: [SOGoCalendarComponent class]]) componentCalendar = [componentCalendar container];