tags:

views:

186

answers:

1

Ok, i have been buried in MAPKit for quite a while. I have dropping pins from a SQLite DB. Distance locations working, annotations working, looks great. Even my activity indicator works. Then right before I hand off the project, I'm swiping, gesturing, you name it to my cute map, works great, then BOOM! yipes!

Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[UISwipeGestureRecognizer removeFromSuperview]: unrecognized selector sent to instance 0x143cb0'

I'm creating this by code, no IB. Google turned up ZERO. Any tips on tackling this one appreciated! For some reason my mapView freaks out on a SwipeGesture? huh?

+3  A: 

Exceptions of this type, particularly when they are mysterious in origin and involve objects you don't recognize, are usually due to memory management bugs -- overreleasing objects, keeping around pointers to objects w/o retaining them, etc. I'd try running with NSZombieEnabled to see if you can spot the source of the bug. (It is in general a good tool to have at your disposal.) A decent intro to NSZombieEnabled is:

http://www.fromconcentratesoftware.com/2007/08/09/nszombieenabled-for-the-debugger-adverse/

Josh Bleecher Snyder