Re: Help with crashing
Re: Help with crashing
- Subject: Re: Help with crashing
- From: Finlay Dobbie <email@hidden>
- Date: Sat, 8 Mar 2003 16:09:42 +0000
On Saturday, March 8, 2003, at 03:55 pm, John McGruer wrote:
The crash occurs when any window is closed and the source of the
problem does not seem to be directly in my code (I not sure exactly
what CFArray - as opposed to NSArray - is). It seems to me that the
Cocoa runtime is trying to deallocate an Array that I have already
deallocated, perhaps? I have checked (and double and triple checked)
any references to arrays I have and retains/releases seem to be
balanced correctly, and I am not sure why there should be an attempt
to deallocate an array in the main application thread. Any help with
this problem would be appreciated! Cheers...
Indeed, you are correct - you are not balancing your AUTOreleases,
releases and retains. The object has already been deallocated, and when
control passes back to the application runloop, the attempt to pop the
autorelease pool results in the pool attempting to release the object.
Actually, it's one of the values in your array that has gone away, and
it's the attempt of the array to release all the values which is
failing. CFArray is the underlying implementation of NSArray, see the
documentation on CoreFoundation.
-- Finlay
_______________________________________________
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.