Re: if statement causing 32 Byte leak?
Re: if statement causing 32 Byte leak?
- Subject: Re: if statement causing 32 Byte leak?
- From: Dave Camp <email@hidden>
- Date: Mon, 11 Jan 2010 07:55:53 -0800
On Jan 10, 2010, at 6:51 PM, Scott Ribe wrote:
>> Just a quick note: one problem with this is false positives; you don't
>> necessarily control all the code that handles the object in question.
>
> I think perhaps you didn't notice that he said "at -dealloc time". There is
> no case in which an autorelease pool should have a reference to an object
> when the object is being dealloc'd. At all other times of course, there may
> be references in autorelease pools which were correctly put there by library
> code after a retain.
That's just a specific instance of a stale pointer (or over-release) problem. If I was going to ask Apple for help here, I'd ask for a debug API that uses the Leaks engine to find things that still have pointers to my object at dealloc time. That would be a huge help sometimes.
Dave
_______________________________________________
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