Re: which cocoa objects to dealloc ?
Re: which cocoa objects to dealloc ?
- Subject: Re: which cocoa objects to dealloc ?
- From: Paul Lynch <email@hidden>
- Date: Sat, 18 Mar 2006 10:37:05 +0000
On 18 Mar 2006, at 10:25, Karim Morsy wrote:
put logs in all of my custom object''s dealloc methods and
obviously none of them seems to get called when the app terminates.
for example, my custom NSView... when I send release to it before
the app quites nothing happens. if I send release twice the app
crashes. so in short...do I have to explicitly send dealloc to ANY
custom object I create, be it a view, a controller, or something
else ?
I have no idea why you are trying to send dealloc, or release, to
your objects. These methods are responsible for freeing memory, and
when your app terminates, the memory taken by the process is freed by
the system.
Never send dealloc yourself. Sending release/dealloc to a freed
object will cause a crash, that is correct behaviour.
Paul
_______________________________________________
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