views:

18

answers:

1

I have NSZombieEnabled to NO in my arguments.

I am checking to see if it is enabled:

if(getenv("NSZombieEnabled") || getenv("NSAutoreleaseFreedObjectCheckEnabled")) 
    {
        NSLog(@"NSZombieEnabled/NSAutoreleaseFreedObjectCheckEnabled enabled!");
    }

My debugger says it is still enabled. Why?

+1  A: 

try to uncheck it. If it has no checkmark in front it shouldn't be passed to the application.

It should be off when you set the value to NO, but getenv("NSZombieEnabled") will return "NO". Which is not a boolean NO but a cstring "NO". So the if condition will be true anyway.

fluchtpunkt