Debugging a freaking EXC BAD ACCESS in iOS App
One of the exception that I often run into in any iOS app development is the freaking EXC BAD ACCESS . An error which is occurs due to error in memory management, e.g. accessing an object that has been release or passing an invalid pointer to a system call (delegate call). Enough saying, so how do you trace it down and find the object that you are trying to access and cause that exception? Well there is 2 ways: NSZombie which is mentioned in Apple developer library's Memory Management guide Instrument tools to profile your app. See this article for details on this tools. To use NSZombie class you simple add NSZombieEnabled into your project Environment Variable . You can access the Environment Variable settings screen by clicking Product > Edit Scheme from the menu. Expand Environment Variables section and click on the + icon. Add NSZombieEnabled into the field. (you can also add NSAutoreleaseFreedObjectC...