Re: My bug or Apple's?
Re: My bug or Apple's?
- Subject: Re: My bug or Apple's?
- From: Ricky Sharp <email@hidden>
- Date: Fri, 19 Nov 2004 21:29:24 -0600
On Nov 19, 2004, at 5:04 PM, John Stiles wrote:
Well, as a matter of course, I try to release everything I allocate.
At my work, our allocator code will complain about a memory leak if I
don't.
In this particular case, TSHashTables destroy each of their elements
when they are destroyed, because that's how they were designed.
Usually it's helpful. :)
If I just wanted to leak the images, I could make my Image class'
destructor do nothing, but that seems like an error to me. Yes, in
this particular instance we're quitting anyway, so we don't HAVE to
free. But should I really need to make two separate types of Image
objects--one that frees itself on destruction, and one that
doesn't--just because of this bug? It doesn't seem logical to me.
Is there any API in TSHashTables that you can call before static
de-initialize time to release all the objects? If so, just call that
from say your delegate's applicationWillTerminate: method.
___________________________________________________________
Ricky A. Sharp mailto:email@hidden
Instant Interactive(tm) http://www.instantinteractive.com
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden