我有一个用于显示地图和自定义注释的应用程序.当用户触摸注释时,我的应用程序崩溃.它仅在iOS 7中发生.它适用于iOS 6和iOS 5.
以下是控制台中显示的崩溃报告:
ERROR: Trying to select an annotation which has not been added
-[__NSSetM coordinate]: unrecognized selector sent to instance 0x18c9d580
*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[__NSSetM coordinate]: unrecognized selector sent to instance 0x18c9d580'
*** First throw call stack:
(
0 CoreFoundation 0x020415e4 __exceptionPreprocess + 180
1 libobjc.A.dylib 0x016918b6 objc_exception_throw + 44
2 CoreFoundation 0x020de903 -[NSObject(NSObject) doesNotRecognizeSelector:] + 275
3 CoreFoundation 0x0203190b ___forwarding___ + 1019
4 CoreFoundation 0x0206e46e __forwarding_prep_1___ + 14
5 MapKit …Run Code Online (Sandbox Code Playgroud)