Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

seepel

macrumors 6502
Original poster
Dec 22, 2009
471
1
I have an app that when run normally crashes silently, nothing printed to the console whatsoever. When run in build and debug I finally get that familiar EXC_BAD_ACCESS at the bottom (nothing shows up with bt though), along with some nonsense that I can't decipher in the debugger window. I've tried to find the problem with NSLog, but as far as I can tell all my functions get hit and finish. I've also tried turning on NSZombies, nut I don't think I fully understand this process. There is a lot of code, and I'm not sure where the problem is so I'm not posting it, but I am wondering if anyone has any good strategies for this kind of thing?
 

seepel

macrumors 6502
Original poster
Dec 22, 2009
471
1
Can you post the nonsense you can't understand from the debugger?

Well here's the back trace (which for some reason I didn't see before...) and the debugger just seems to have a bunch of memory locations I can click through, not sure what to do with them though. Now it suddenly appears to be a problem with core data.. but still quite cryptic to me.

Code:
(gdb) bt
#0  0x02b50c97 in objc_msgSend ()
#1  0x04b74f30 in ?? ()
#2  0x0296c012 in __CFArrayReleaseValues ()
#3  0x0294aed0 in _CFRelease ()
#4  0x0278b999 in -[_PFManagedObjectReferenceQueue _processReferenceQueue:] ()
#5  0x027bd54a in _performRunLoopAction ()
#6  0x029a3a52 in __CFRunLoopDoObservers ()
#7  0x02970345 in CFRunLoopRunSpecific ()
#8  0x0296f8a8 in CFRunLoopRunInMode ()
#9  0x032b289d in GSEventRunModal ()
#10 0x032b2962 in GSEventRun ()
#11 0x002e2372 in UIApplicationMain ()
#12 0x00002a08 in main (argc=2, argv=0xbfffef54) at /Users/slynch/Documents/src/Pigeon/main.m:14
 

seepel

macrumors 6502
Original poster
Dec 22, 2009
471
1
So I tracked down the problem, and of course, I over released an object. I set an object contained in an autoreleased object, to autorelease again and it got all messed up. Although I didn't learn anything about debugging, I simply used the old NSLog method...
 

themoonisdown09

macrumors 601
Nov 19, 2007
4,319
18
Georgia, USA
So I tracked down the problem, and of course, I over released an object. I set an object contained in an autoreleased object, to autorelease again and it got all messed up. Although I didn't learn anything about debugging, I simply used the old NSLog method...

The easiest way to track down EXC_BAD_ACCESS errors is by turning on Zombies. Read this post to find out how to do that. It sure has helped me.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.