Re: Debugging retainCount
Re: Debugging retainCount
- Subject: Re: Debugging retainCount
- From: The Amazing Llama <email@hidden>
- Date: Tue, 15 Jul 2003 08:26:33 -0700
On Monday, July 14, 2003, at 09:00 PM, Angela Brett wrote:
I've always kind of been of the opinion that releasing an already
freed
object ought to be a non-fatal error, myself. But I'm sure there are
lots of good arguments on both side of that issue.
I know you didn't mean to start a debate on this issue, but think about
this consequence. That would mean something would have to be kept
around
in place of that object in order to make sure nothing bad happened when
the same address was sent another release message. And if something
else
is kept around in place of a deallocated object, that defeats the whole
point of deallocating the object since the memory is not available for
something else to use. The whole thing would be one big memory leak.
Fine
for debugging I guess (I vaguely recall a setting which actually does
this
-- NSZombieEnabled? I've never used it myself) but awful for a real
application.
Yes, it is NSZombieEnabled, and it's very useful if you, like me, keep
having this same autorelease snafu.
Seth A. Roby The Amazing Llama < mail or AIM me at tallama at mac dot
com>
"Life is like an exploded clown. It's really funny until you figure out
what just happened."
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.