Re: Help with crashing
Re: Help with crashing
- Subject: Re: Help with crashing
- From: email@hidden
- Date: Sat, 8 Mar 2003 16:59:59 +0100
On samedi, mars 8, 2003, at 04: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...
You can consider that a CFArray is a NSArray.
The deallocation made in the main thread comes for the Autorelease
mechanism.
You should check that you're not doing a release call on an object that
was given to you as an autoreleased object.
For instance, if you're using this:
myArray=[NSArray arrayWithObjets:myObject1,myObject2,etc...];
// Do my stuff
[myArray release];
Then you will see your crash.
_______________________________________________
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.