I'm stuck with a problem in emulator. The emulator occasionally stops with
Program received signal: "EXC_BAD_ACCESS" .
as console output. No further info prov开发者_运维问答ided. Is there a chance to come closer to the problem?
I see that NSZombie already has been proposed, but the link doesn't seem to work anymore, so here's instructions on how to use it.
To activate NSZombie do the following:
- Get info of the executable.
- Go to the arguments tab.
- In the "Variables to be set in the environment:" section add:
Name: NSZombieEnabled Value: YES
Then run your app as usual and when it crashes it should tell you which deallocated object received the release message.
This often is caused by sending a message to an object that is no longer in memory. There is no error message because there is nothing on the stack when the error occurs. You can set breakpoints and step through your application until you find where the crash occurs, or you can use nszombie.
http://howtomakeiphoneapps.com/2009/02/nszombie-and-xcode-oh-my/
精彩评论