Why I have a leak? I am unable to understand
Why I have a leak? I am unable to understand
- Subject: Why I have a leak? I am unable to understand
- From: Agha Khan <email@hidden>
- Date: Mon, 24 Aug 2009 17:20:10 -0700
HI:
I know the leak is in next 2 lines
I have commented all the code except these 2 lines.
// NSTimeInterval
NSCalendar *gregorian = [[NSCalendar alloc]
initWithCalendarIdentifier:NSGregorianCalendar];
unsigned unitFlags = NSYearCalendarUnit | NSMonthCalendarUnit |
NSDayCalendarUnit | NSHourCalendarUnit | NSMinuteCalendarUnit |
NSSecondCalendarUnit;
NSDateComponents *dateSegments = [gregorian components:unitFlags
fromDate:[NSDate date]];
I am not releasing gregorian, because I never used retain.
Same is true with dateSegments.
Can someone help me.
Why I have a leak? I am unable to understand?
Thanks in advance.
Agha
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden