my application keep crashing when i try to open notifications by clicking on notification badge..i got the following crash report
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Triggered by Thread: 0
Last Exception Backtrace:
0 CoreFoundation 0x24d33132 __exceptionPreprocess + 122
1 libobjc.A.dylib 0x32c8fc72 objc_exception_throw + 34
2 CoreFoundation 0x24d385f8 -[NSObject(NSObject) doesNotRecognizeSelector:] + 184
3 CoreFoundation 0x24d364d4 ___forwarding___ + 708
4 CoreFoundation 0x24c659d4 _CF_forwarding_prep_0 + 20
5 Skopic 0x000f7062 -[AppDelegate application:didReceiveRemoteNotification:] (AppDelegate.m:209)
6 UIKit 0x285d8c7c -[UIApplication _handleNonLaunchSpecificActions:forScene:withTransitionContext:] + 1836
7 UIKit 0x285d06a2 -[UIApplication workspace:didReceiveActions:] + 102
8 FrontBoardServices 0x2b7ccebc __31-[FBSSerialQueue performAsync:]_block_invoke_2 + 12
9 CoreFoundation 0x24cf9250 __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ + 8
10 CoreFoundation 0x24cf8514 __CFRunLoopDoBlocks + 212
11 CoreFoundation 0x24cf706e __CFRunLoopRun + 1710
12 CoreFoundation 0x24c4299c CFRunLoopRunSpecific + 472
13 CoreFoundation 0x24c427ae CFRunLoopRunInMode + 102
14 GraphicsServices 0x2c3f41a4 GSEventRunModal + 132
15 UIKit 0x283cd690 UIApplicationMain + 1436
16 Skopic 0x000f46fc main (main.m:15)
17 libdyld.dylib 0x33237aaa tlv_initializer + 2
Thread 0 name: Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0 libsystem_kernel.dylib 0x332fddf0 __pthread_kill + 8
1 libsystem_pthread.dylib 0x3337ec92 pthread_kill + 58
2 libsystem_c.dylib 0x3329c934 abort + 72
3 libc++abi.dylib 0x3249bbb8 abort_message + 84
4 libc++abi.dylib 0x324b566a default_terminate_handler() + 262
5 libobjc.A.dylib 0x32c8ff0e _objc_terminate() + 190
6 libc++abi.dylib 0x324b2dec std::__terminate(void (*)()) + 76
7 libc++abi.dylib 0x324b28b4 __cxa_rethrow + 96
8 libobjc.A.dylib 0x32c8fdba objc_exception_rethrow + 38
9 CoreFoundation 0x24c42a38 CFRunLoopRunSpecific + 628
10 CoreFoundation 0x24c427ae CFRunLoopRunInMode + 102
11 GraphicsServices 0x2c3f41a4 GSEventRunModal + 132
12 UIKit 0x283cd690 UIApplicationMain + 1436
13 Skopic 0x000f46fc main (main.m:15)
14 libdyld.dylib 0x33237aac start + 0
can someone explain why these crashes keep occurring?
I don't think it makes sense to turn the NSDictionary into another NSDictionary with [NSDictionary dictionaryWithDictionary:] ... also NSDictionary can be non-nil but contain 0 key entries (an empty dictionary).
Perhaps you want: NSDictionary *apnsPayload = [userInfo objectForKey: #"alert"]; ?
See:
Related
We have encountered the crash : -[WKSyntheticTapGestureRecognizer setState:] in our app.I am also attaching crash report for the reference:
Crashed: com.apple.main-thread
0 libobjc.A.dylib 0x1540 objc_msgSend + 32
1 WebKit 0x4a6bd8 -[WKSyntheticTapGestureRecognizer setState:] + 100
2 UIKitCore 0x2bb320 -[UITapRecognizer tooSlow:] + 76
3 Foundation 0x365fc __NSFireDelayedPerform + 460
4 CoreFoundation 0xae318 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ + 32
5 CoreFoundation 0x32cf0 __CFRunLoopDoTimer + 1076
6 CoreFoundation 0x2d4ec __CFRunLoopDoTimers + 328
7 CoreFoundation 0xbd08 __CFRunLoopRun + 1944
8 CoreFoundation 0x1f468 CFRunLoopRunSpecific + 600
9 GraphicsServices 0x138c GSEventRunModal + 164
10 UIKitCore 0x51a088 -[UIApplication _run] + 1100
11 UIKitCore 0x298958 UIApplicationMain + 2092
12 Adoddle Field Plus 0x1238f0 main + 17 (main.mm:17)
13 ??? 0x10817daa4 (Missing)
KERN_INVALID_ADDRESS at 0x0000000000000010
Like WKSyntheticTapGesturestabilizer has been released and is still accessing its member variables
Can anyone tell me what line to look at to see why my app crashed ? This is my first time experiencing a crash log and im kind of lost as in what direction to go in. Also if anyone is familiar with these could you tell me what are possible reasons this crash occured ?
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Triggered by Thread: 0
Application Specific Information:
abort() called
Last Exception Backtrace:
0 CoreFoundation 0x198217758 __exceptionPreprocess + 232
1 libobjc.A.dylib 0x19741fd00 objc_exception_throw + 59
2 CoreFoundation 0x1981306ac -[NSObject+ 222892 (NSObject) doesNotRecognizeSelector:] + 143
3 UIKitCore 0x1c5124aa8 -[UIResponder doesNotRecognizeSelector:] + 287
4 CoreFoundation 0x19821d0fc ___forwarding___ + 1411
5 CoreFoundation 0x19821eeb0 _CF_forwarding_prep_0 + 95
6 Foundation 0x198cb72f4 __NSFireTimer + 87
7 CoreFoundation 0x1981a7fb8 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ + 31
8 CoreFoundation 0x1981a7ce4 __CFRunLoopDoTimer + 899
9 CoreFoundation 0x1981a74c8 __CFRunLoopDoTimers + 251
10 CoreFoundation 0x1981a2198 __CFRunLoopRun + 1811
11 CoreFoundation 0x1981a1764 CFRunLoopRunSpecific + 451
12 GraphicsServices 0x19a3dddd4 GSEventRunModal + 107
13 UIKitCore 0x1c50f800c UIApplicationMain + 215
14 Game 0x1041a116c 0x104120000 + 528748
15 libdyld.dylib 0x197c60ffc start + 3
Thread 0 Crashed:
0 libsystem_kernel.dylib 0x0000000197dac0bc __pthread_kill + 8
1 libsystem_c.dylib 0x0000000197d05250 __abort + 156
2 libsystem_c.dylib 0x0000000197d051b4 __abort + 0
3 libc++abi.dylib 0x0000000197407ff0 __cxa_bad_cast + 0
4 libc++abi.dylib 0x00000001974081b4 default_unexpected_handler+ 8628 () + 0
5 libobjc.A.dylib 0x0000000197420144 _objc_terminate+ 24900 () + 124
6 libc++abi.dylib 0x00000001974149d4 std::__terminate(void (*)+ 59860 ()) + 20
7 libc++abi.dylib 0x00000001974145cc __cxa_rethrow + 148
8 libobjc.A.dylib 0x000000019741fee0 objc_exception_rethrow + 48
9 CoreFoundation 0x00000001981a17d0 CFRunLoopRunSpecific + 560
10 GraphicsServices 0x000000019a3dddd4 GSEventRunModal + 108
11 UIKitCore 0x00000001c50f800c UIApplicationMain + 216
12 Game 0x00000001041a116c 0x104120000 + 528748
13 libdyld.dylib 0x0000000197c60ffc start + 4
I got a crash for my own app on my iPhone, and am trying to figure out what happened. Here is the relevant part from the crash log in Xcode (sorry for the poor formatting):
Exception Type: EXC_CRASH (SIGABRT) Exception Codes:
0x0000000000000000, 0x0000000000000000 Exception Note:
EXC_CORPSE_NOTIFY Triggered by Thread: 0
Application Specific Information: abort() called
Filtered syslog: None found
Last Exception Backtrace: 0 CoreFoundation
0x1828c2d8c exceptionPreprocess + 228 1 libobjc.A.dylib
0x181a7c5ec objc_exception_throw + 55 2 CoreFoundation
0x1828d0098 -[NSObject+ 1388696 (NSObject) doesNotRecognizeSelector:]
+ 139 3 CoreFoundation 0x1828c85c8 ___forwarding_ + 1379 4 CoreFoundation 0x1827ae41c _CF_forwarding_prep_0 + 91 5 MyApp 0x102c33a0c 0x102bf0000 + 277004 6 MyApp
0x102c39d9c 0x102bf0000 + 302492 7 MyApp
0x102c1bed8 0x102bf0000 + 179928 8 MyApp
0x102c0754c 0x102bf0000 + 95564 9 libdispatch.dylib
0x1821b4aa0 _dispatch_call_block_and_release + 23 10
libdispatch.dylib 0x1821b4a60 _dispatch_client_callout +
15 11 libdispatch.dylib 0x1821f5bcc
_dispatch_main_queue_callback_4CF$VARIANT$armv81 + 527 12 CoreFoundation 0x18286b070
CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE + 11 13 CoreFoundation 0x182868bc8 __CFRunLoopRun + 2271 14
CoreFoundation 0x182788da8 CFRunLoopRunSpecific + 551
15 GraphicsServices 0x18476e020 GSEventRunModal + 99 16
UIKit 0x18c7a8758 UIApplicationMain + 235 17
MyApp 0x102bf48f4 0x102bf0000 + 18676 18
libdyld.dylib 0x182219fc0 start + 3
Thread 0 name: Dispatch queue: com.apple.main-thread Thread 0
Crashed: 0 libsystem_kernel.dylib 0x00000001823492e0
pthread_kill + 8 1 libsystem_pthread.dylib 0x00000001824ee6a8 pthread_kill$VARIANT$armv81 + 360 2
libsystem_c.dylib 0x00000001822b7d0c abort + 140 3
libc++abi.dylib 0x0000000181a532c8 __cxa_bad_cast + 0 4
libc++abi.dylib 0x0000000181a53470
default_unexpected_handler+ 5232 () + 0 5 libobjc.A.dylib
0x0000000181a7c8d4 _objc_terminate+ 35028 () + 124 6
libc++abi.dylib 0x0000000181a6d37c
std::__terminate(void ()+ 111484 ()) + 16 7 libc++abi.dylib
0x0000000181a6cccc __cxxabiv1::exception_cleanup_func+ 109772
(_Unwind_Reason_Code, _Unwind_Exception) + 0 8 libobjc.A.dylib
0x0000000181a7c720 _objc_exception_destructor+ 34592 (void*) + 0 9
CoreFoundation 0x00000001828d0098
__methodDescriptionForSelector + 0 10 CoreFoundation 0x00000001828c85c8 ___forwarding_ + 1380 11 CoreFoundation
0x00000001827ae41c _CF_forwarding_prep_0 + 92 12 MyApp
0x0000000102c33a0c 0x102bf0000 + 277004 13 MyApp 0x0000000102c39d9c 0x102bf0000 + 302492 14 MyApp 0x0000000102c1bed8 0x102bf0000 + 179928 15 MyApp 0x0000000102c0754c 0x102bf0000 + 95564 16 libdispatch.dylib 0x00000001821b4aa0 _dispatch_call_block_and_release + 24 17
libdispatch.dylib 0x00000001821b4a60
_dispatch_client_callout + 16 18 libdispatch.dylib 0x00000001821f5bcc _dispatch_main_queue_callback_4CF$VARIANT$armv81 +
528 19 CoreFoundation 0x000000018286b070
CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE + 12 20 CoreFoundation 0x0000000182868bc8 __CFRunLoopRun +
2272 21 CoreFoundation 0x0000000182788da8
CFRunLoopRunSpecific + 552 22 GraphicsServices
0x000000018476e020 GSEventRunModal + 100 23 UIKit
0x000000018c7a8758 UIApplicationMain + 236 24 MyApp
0x0000000102bf48f4 0x102bf0000 + 18676 25 libdyld.dylib 0x0000000182219fc0 start + 4
So I do see some errors but they are all non-specific, not pointing to a specific call.
Can I extract more info from this log or somewhere else to figure out what could have gone wrong?
I'm getting a rare crash in my iOS app when resuming from the background. I see -[NSObject doesNotRecognizeSelector:] in the exception backtrace but there is little more information. Any idea where I might start looking?
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Triggered by Thread: 0
Application Specific Information:
abort() called
Filtered syslog:
None found
Last Exception Backtrace:
0 CoreFoundation 0x18f7291b8 __exceptionPreprocess + 124
1 libobjc.A.dylib 0x18e16055c objc_exception_throw + 55
2 CoreFoundation 0x18f730268 -[NSObject+ 1274472 (NSObject) doesNotRecognizeSelector:] + 139
3 CoreFoundation 0x18f72d270 ___forwarding___ + 915
4 CoreFoundation 0x18f62680c _CF_forwarding_prep_0 + 91
5 CoreFoundation 0x18f6d6b5c __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 23
6 CoreFoundation 0x18f6d6434 __CFRunLoopDoSources0 + 411
7 CoreFoundation 0x18f6d40a4 __CFRunLoopRun + 803
8 CoreFoundation 0x18f6022b8 CFRunLoopRunSpecific + 443
9 GraphicsServices 0x1910b6198 GSEventRunModal + 179
10 UIKit 0x1956427fc -[UIApplication _run] + 683
11 UIKit 0x19563d534 UIApplicationMain + 207
12 MyApp 0x100040d04 0x10003c000 + 19716
13 libdyld.dylib 0x18e5e55b8 start + 3
Thread 0 name: Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0 libsystem_kernel.dylib 0x000000018e6f7014 __pthread_kill + 8
1 libsystem_pthread.dylib 0x000000018e7bf450 pthread_kill + 112
2 libsystem_c.dylib 0x000000018e66b400 abort + 140
3 libc++abi.dylib 0x000000018e1352d4 __cxa_bad_cast + 0
4 libc++abi.dylib 0x000000018e152cc0 default_unexpected_handler+ 126144 () + 0
5 libobjc.A.dylib 0x000000018e160844 _objc_terminate+ 34884 () + 124
6 libc++abi.dylib 0x000000018e14f66c std::__terminate(void (*)+ 112236 ()) + 16
7 libc++abi.dylib 0x000000018e14f234 __cxa_rethrow + 144
8 libobjc.A.dylib 0x000000018e16071c objc_exception_rethrow + 44
9 CoreFoundation 0x000000018f60232c CFRunLoopRunSpecific + 560
10 GraphicsServices 0x00000001910b6198 GSEventRunModal + 180
11 UIKit 0x00000001956427fc -[UIApplication _run] + 684
12 UIKit 0x000000019563d534 UIApplicationMain + 208
13 MyApp 0x0000000100040d04 0x10003c000 + 19716
14 libdyld.dylib 0x000000018e5e55b8 start + 4
It seems that you are calling a method that dosen't belong to an object. It means your object on which you are calling a method is NSObject type and a method that you are calling is not availabel on NSObject. This used to happen when we are doing type casting.
For eg.
NSObject *obj = [NSObject new];
[(UIView *)obj setBackgroundColor:[UIColor whiteColor]]; // it will crash for unrecognize selector call
So the solution is to check the object using isKindOfClass: and then call a method thats belongs to it.
I'm trying to analyze a log for what appears to be an intermittent crash.
Here's the stack trace for the thread that throws the exception:
Thread : Fatal Exception: NSInvalidArgumentException
0 CoreFoundation 0x2ab5f49f __exceptionPreprocess + 126
1 libobjc.A.dylib 0x38315c8b objc_exception_throw + 38
2 CoreFoundation 0x2ab5f3e5 -[NSException initWithCoder:]
3 Foundation 0x2b862389 -[NSProxy doesNotRecognizeSelector:] + 68
4 CoreFoundation 0x2ab627d7 ___forwarding___ + 714
5 CoreFoundation 0x2aa94058 _CF_forwarding_prep_0 + 24
6 UIKit 0x292648cb -[UIScrollViewAccessibility _axCleanupDelegateClearer] + 98
7 UIKit 0x29264965 -[UIScrollViewAccessibility dealloc] + 60
8 UIKit 0x2e19c8b1 -[UITableView dealloc] + 1572
9 UIKit 0x2924dc91 -[UITableViewAccessibility dealloc] + 172
10 libobjc.A.dylib 0x38314da1 object_cxxDestructFromClass(objc_object*, objc_class*) + 116
11 libobjc.A.dylib 0x3831e5f7 objc_destructInstance + 34
12 libobjc.A.dylib 0x3831e61b object_dispose + 14
13 UIKit 0x2e3214d1 -[UIResponder dealloc] + 96
14 UIKit 0x2e18eb55 -[UIViewController dealloc] + 1760
15 CoreFoundation 0x2aa6600d CFRelease + 600
16 CoreFoundation 0x2aa7968f -[__NSArrayI dealloc] + 66
17 libobjc.A.dylib 0x3832fd5f objc_object::sidetable_release(bool) + 166
18 libobjc.A.dylib 0x383301a9 (anonymous namespace)::AutoreleasePoolPage::pop(void*) + 404
19 CoreFoundation 0x2aa71149 _CFAutoreleasePoolPop + 16
20 UIKit 0x2e01789f _wrapRunLoopWithAutoreleasePoolHandler + 42
21 CoreFoundation 0x2ab25d95 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 20
22 CoreFoundation 0x2ab23453 __CFRunLoopDoObservers + 278
23 CoreFoundation 0x2ab2385b __CFRunLoopRun + 914
24 CoreFoundation 0x2aa713c1 CFRunLoopRunSpecific + 476
25 CoreFoundation 0x2aa711d3 CFRunLoopRunInMode + 106
26 GraphicsServices 0x31e6f0a9 GSEventRunModal + 136
27 UIKit 0x2e080fa1 UIApplicationMain + 1440
28 MyApp 0x000938b1 main (main.mm:21)
29 libdyld.dylib 0x38895aaf start + 2
And here's the stack trace for the main thread:
Thread : Crashed: com.apple.main-thread
0 libsystem_kernel.dylib 0x3895bdfc __pthread_kill + 8
1 libsystem_pthread.dylib 0x389d9d37 pthread_kill + 62
2 libsystem_c.dylib 0x388fb909 abort + 76
3 libc++abi.dylib 0x37c399c9 __cxa_bad_cast
4 libc++abi.dylib 0x37c53671 default_unexpected_handler()
5 libobjc.A.dylib 0x38315f25 _objc_terminate() + 192
6 libc++abi.dylib 0x37c50de3 std::__terminate(void (*)()) + 78
7 libc++abi.dylib 0x37c508af __cxa_rethrow + 102
8 libobjc.A.dylib 0x38315dd3 objc_exception_rethrow + 42
9 CoreFoundation 0x2aa7145d CFRunLoopRunSpecific + 632
10 CoreFoundation 0x2aa711d3 CFRunLoopRunInMode + 106
11 GraphicsServices 0x31e6f0a9 GSEventRunModal + 136
12 UIKit 0x2e080fa1 UIApplicationMain + 1440
13 MyApp 0x000938b1 main (main.mm:21)
Looking through the trace with the exception, I see a CF_forwarding_prep_0 message, which is followed by an [NSProxy doesNotRecognizeSelector] exception. Reading that, is it a safe assumption that the cause of the issue is that there's a pointer to a tableview delegate that isn't being set to nil? That's about the only discernible thing I see here.
Any help would be most appreciated. Thanks!