Re: Enabling NSZombieEnabled programatically
Re: Enabling NSZombieEnabled programatically
- Subject: Re: Enabling NSZombieEnabled programatically
- From: Jim Correia <email@hidden>
- Date: Sat, 9 Jan 2010 23:46:03 -0500
On Jan 9, 2010, at 7:54 PM, Graham Cox wrote:
> I'm getting something odd though. If I set NSZombieEnabled during app delegate -applicationDidFinishLaunching: method from my preference, a later deliberate over-release still causes a EXC_BAD_ACCESS. If I set it as an environment variable (Xcode launch arguments for my app) I get the zombie logged as expected. In either case I can see that NSZombieEnabled is YES, but directly setting it doesn't appear to work.
>
> Any idea what I'm doing wrong?
>
> Code:
>
> #include <Foundation/NSDebug.h>
>
>
> - (void) applicationDidFinishLaunching:(NSNotification*) aNotification
The comment in NSDebug.h reads:
"This is mostly a benefit if you need to initialize these variables to some non-default value before your program's main() routine gets control”
My guess is that -applicationDidFinishLauching: time is too late.
- Jim_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden