iOS

Enable NSZombie for Debugging Crashes

I posted a tip before on how you can find the real cause of exception in Xcode.

There is another feature which you can enable to help in debugging.

NSZombie is an option that helps to trace overreleasing of objects.

Sometimes you might encounter exceptions objc_msgSend, which no matter how many times you Continue, an exception is thrown. That is a good sign get help from the zombie.

To enable, go to Product > Edit Scheme > Diagnostics, and check Enable Zombie Objects.

Run and debug again, and more meaningful info of what was deallocated wrongly will be shown.

Comments