I'm getting a really weird behavior, my app crashes almost only with the device (I did manage to reproduce the bug on the simulator, but only twice), and only when it is not running from Xcode.
What happens is, I can, sometimes, reproduce the bug by closing the app from the multitask, opening it again, locking the screen fast and unlocking the screen.
Also I get different errors sometimes.
Crash log 1:
Incident Identifier: F2997747-0068-4DA7-BDB8-734B786855E9
CrashReporter Key: 369354cb12966b72d136b40418726dd923de7aae
Hardware Model: iPhone5,1
Process: HomeAutomation [813]
Path: /var/mobile/Applications/6F99E387-2530-4433-8DB8-0B657C4F9742/HomeAutomation.app/HomeAutomation
Identifier: com.carbon306.HomeAutomation
Version: 1.0 (1.0)
Code Type: ARM (Native)
Parent Process: launchd [1]
Date/Time: 2013-10-12 01:49:50.880 -0300
OS Version: iOS 7.0.2 (11A501)
Report Version: 104
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Subtype: KERN_INVALID_ADDRESS at 0x717ec19e
Triggered by Thread: 6
Thread 0:
0 libsystem_kernel.dylib 0x38610a84 mach_msg_trap + 20
1 libsystem_kernel.dylib 0x3861087c mach_msg + 36
2 CoreFoundation 0x2dd4355c __CFRunLoopServiceMachPort + 152
3 CoreFoundation 0x2dd41cc2 __CFRunLoopRun + 858
4 CoreFoundation 0x2dcac53c CFRunLoopRunSpecific + 520
5 CoreFoundation 0x2dcac31e CFRunLoopRunInMode + 102
6 GraphicsServices 0x329e32e6 GSEventRunModal + 134
7 UIKit 0x305631e0 UIApplicationMain + 1132
8 HomeAutomation 0x000dbca0 0xd6000 + 23712
9 libdyld.dylib 0x3856cab4 start + 0
Thread 1:
0 libsystem_kernel.dylib 0x38610838 kevent64 + 24
1 libdispatch.dylib 0x3855f0d0 _dispatch_mgr_invoke + 228
2 libdispatch.dylib 0x3855963e _dispatch_mgr_thread + 34
Thread 2:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 3:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 4:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 5 name: com.apple.NSURLConnectionLoader
Thread 5:
0 libsystem_kernel.dylib 0x38610a84 mach_msg_trap + 20
1 libsystem_kernel.dylib 0x3861087c mach_msg + 36
2 CoreFoundation 0x2dd4355c __CFRunLoopServiceMachPort + 152
3 CoreFoundation 0x2dd41c7c __CFRunLoopRun + 788
4 CoreFoundation 0x2dcac53c CFRunLoopRunSpecific + 520
5 CoreFoundation 0x2dcac31e CFRunLoopRunInMode + 102
6 Foundation 0x2e6e764c +[NSURLConnection(Loader) _resourceLoadLoop:] + 316
7 Foundation 0x2e75cdc2 __NSThread__main__ + 1058
8 libsystem_pthread.dylib 0x38689c5a _pthread_body + 138
9 libsystem_pthread.dylib 0x38689bca _pthread_start + 98
10 libsystem_pthread.dylib 0x38687ccc thread_start + 4
Thread 6 Crashed:
0 libobjc.A.dylib 0x3806eb66 objc_msgSend + 6
1 libdispatch.dylib 0x38558100 _dispatch_call_block_and_release + 8
2 libdispatch.dylib 0x3855d7e0 _dispatch_root_queue_drain + 220
3 libdispatch.dylib 0x3855d9cc _dispatch_worker_thread2 + 52
4 libsystem_pthread.dylib 0x38687dfc _pthread_wqthread + 296
5 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 7:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 8:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 9 name: com.apple.CFSocket.private
Thread 9:
0 libsystem_kernel.dylib 0x38623440 select$DARWIN_EXTSN + 20
1 CoreFoundation 0x2dd4745e __CFSocketManager + 482
2 libsystem_pthread.dylib 0x38689c5a _pthread_body + 138
3 libsystem_pthread.dylib 0x38689bca _pthread_start + 98
4 libsystem_pthread.dylib 0x38687ccc thread_start + 4
Thread 10:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 11:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 12:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 6 crashed with ARM Thread State (32-bit):
r0: 0x17ea6320 r1: 0x30b5f763 r2: 0x00000000 r3: 0x00000003
r4: 0x17d96b30 r5: 0x00000000 r6: 0x001c0840 r7: 0x02ac5f8c
r8: 0x00000001 r9: 0x717ec192 r10: 0x00000000 r11: 0x00000000
ip: 0x38b94224 sp: 0x02ac5f88 lr: 0x38558103 pc: 0x3806eb66
cpsr: 0x60000030
Crash log 2:
Incident Identifier: D605BD2A-6787-4534-8AB9-BC89A7DD9945
CrashReporter Key: 369354cb12966b72d136b40418726dd923de7aae
Hardware Model: iPhone5,1
Process: HomeAutomation [698]
Path: /var/mobile/Applications/6F99E387-2530-4433-8DB8-0B657C4F9742/HomeAutomation.app/HomeAutomation
Identifier: com.carbon306.HomeAutomation
Version: 1.0 (1.0)
Code Type: ARM (Native)
Parent Process: launchd [1]
Date/Time: 2013-10-12 01:24:29.139 -0300
OS Version: iOS 7.0.2 (11A501)
Report Version: 104
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Triggered by Thread: 4
Last Exception Backtrace:
0 CoreFoundation 0x2dd78e86 __exceptionPreprocess + 126
1 libobjc.A.dylib 0x380736c2 objc_exception_throw + 34
2 CoreFoundation 0x2dd7c7b2 -[NSObject(NSObject) doesNotRecognizeSelector:] + 198
3 CoreFoundation 0x2dd7b0b2 ___forwarding___ + 702
4 CoreFoundation 0x2dcc9e94 __forwarding_prep_0___ + 20
5 libdispatch.dylib 0x385580fe _dispatch_call_block_and_release + 6
6 libdispatch.dylib 0x3855d7e0 _dispatch_root_queue_drain + 220
7 libdispatch.dylib 0x3855d9cc _dispatch_worker_thread2 + 52
8 libsystem_pthread.dylib 0x38687dfa _pthread_wqthread + 294
9 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 0:
0 libsystem_kernel.dylib 0x38610a84 mach_msg_trap + 20
1 libsystem_kernel.dylib 0x3861087c mach_msg + 36
2 CoreFoundation 0x2dd4355c __CFRunLoopServiceMachPort + 152
3 CoreFoundation 0x2dd41cc2 __CFRunLoopRun + 858
4 CoreFoundation 0x2dcac53c CFRunLoopRunSpecific + 520
5 CoreFoundation 0x2dcac31e CFRunLoopRunInMode + 102
6 GraphicsServices 0x329e32e6 GSEventRunModal + 134
7 UIKit 0x305631e0 UIApplicationMain + 1132
8 HomeAutomation 0x000e4d48 0xdf000 + 23880
9 libdyld.dylib 0x3856cab4 start + 0
Thread 1:
0 libsystem_kernel.dylib 0x38610838 kevent64 + 24
1 libdispatch.dylib 0x3855f0d0 _dispatch_mgr_invoke + 228
2 libdispatch.dylib 0x3855963e _dispatch_mgr_thread + 34
Thread 2:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 3:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 4 Crashed:
0 libsystem_kernel.dylib 0x386231fc __pthread_kill + 8
1 libsystem_pthread.dylib 0x3868aa4e pthread_kill + 54
2 libsystem_c.dylib 0x385d4028 abort + 72
3 libc++abi.dylib 0x37a2298a abort_message + 70
4 libc++abi.dylib 0x37a3b6e2 default_terminate_handler() + 250
5 libobjc.A.dylib 0x38073936 _objc_terminate() + 190
6 libc++abi.dylib 0x37a391b0 std::__terminate(void (*)()) + 76
7 libc++abi.dylib 0x37a38a04 __cxa_throw + 112
8 libobjc.A.dylib 0x38073796 objc_exception_throw + 246
9 CoreFoundation 0x2dd7c7b2 -[NSObject(NSObject) doesNotRecognizeSelector:] + 198
10 CoreFoundation 0x2dd7b0b2 ___forwarding___ + 702
11 CoreFoundation 0x2dcc9e94 __forwarding_prep_0___ + 20
12 libdispatch.dylib 0x38558100 _dispatch_call_block_and_release + 8
13 libdispatch.dylib 0x3855d7e0 _dispatch_root_queue_drain + 220
14 libdispatch.dylib 0x3855d9cc _dispatch_worker_thread2 + 52
15 libsystem_pthread.dylib 0x38687dfc _pthread_wqthread + 296
16 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 5:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 6 name: com.apple.NSURLConnectionLoader
Thread 6:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687c98 pthread_workqueue_addthreads_np + 40
2 libdispatch.dylib 0x3855d46c _dispatch_queue_wakeup_global_slow + 52
3 libdispatch.dylib 0x3855c5a6 _dispatch_wakeup + 122
4 libdispatch.dylib 0x3855cbe8 _dispatch_queue_push_list_slow2 + 16
5 libdispatch.dylib 0x3855c5a6 _dispatch_wakeup + 122
6 libdispatch.dylib 0x3855cbe8 _dispatch_queue_push_list_slow2 + 16
7 libdispatch.dylib 0x3855f432 _dispatch_mach_msg_send + 518
8 libdispatch.dylib 0x3855a12e dispatch_mach_send + 166
9 libxpc.dylib 0x386948d2 xpc_connection_send_message + 46
10 libsystem_network.dylib 0x3866384a __net_helper_send_block_invoke + 62
11 libdispatch.dylib 0x3855c8f6 _dispatch_barrier_sync_f_invoke + 22
12 libsystem_network.dylib 0x38661c64 net_helper_send + 164
13 libsystem_network.dylib 0x38661b4c net_helper_client_cancel + 76
14 libsystem_network.dylib 0x3865f384 __tcp_connection_cancel_block_invoke + 156
15 libdispatch.dylib 0x385580ec _dispatch_client_callout + 20
16 libdispatch.dylib 0x3855c8f6 _dispatch_barrier_sync_f_invoke + 22
17 libsystem_network.dylib 0x3865f2da tcp_connection_cancel + 102
18 CFNetwork 0x2d972ab4 SocketStream::close(void const*) + 312
19 CFNetwork 0x2d97294e CoreStreamBase::_streamInterface_Close() + 46
20 CFNetwork 0x2d991286 HTTPReadFilter::_streamImpl_Close() + 66
21 CFNetwork 0x2d97294e CoreStreamBase::_streamInterface_Close() + 46
22 CFNetwork 0x2d9911c6 NetConnection::shutdownConnectionStreams() + 98
23 CFNetwork 0x2d9c51b4 NetConnection::errorOccurred(CFStreamError*) + 56
24 CFNetwork 0x2d988b0a HTTPNetConnection::responseStreamCallback(void*, __CoreReadStream*, unsigned long) + 282
25 CFNetwork 0x2d9889d2 NetConnection::connectionResponse(__CoreReadStream*, unsigned long) + 114
26 CFNetwork 0x2d96cb20 CoreReadStreamClient::coreStreamEventsAvailable(unsigned long) + 32
27 CFNetwork 0x2da131f0 CoreStreamBase::_callClientNow(CoreStreamClient*) + 40
28 CFNetwork 0x2d96c8c2 CoreStreamBase::_streamSetEventAndScheduleDelivery(unsigned long, unsigned char) + 118
29 CFNetwork 0x2d96c76e CoreStreamBase::_streamInterface_SignalEvent(unsigned long, CFStreamError const*) + 30
30 CFNetwork 0x2d9878ca HTTPReadFilter::socketReadStreamCallback(unsigned long) + 342
31 CFNetwork 0x2d987762 HTTPReadFilter::_httpRdFilterStreamCallBack(__CoreReadStream*, unsigned long, void*) + 78
32 CFNetwork 0x2d96cb20 CoreReadStreamClient::coreStreamEventsAvailable(unsigned long) + 32
33 CFNetwork 0x2da131f0 CoreStreamBase::_callClientNow(CoreStreamClient*) + 40
34 CFNetwork 0x2d96c8c2 CoreStreamBase::_streamSetEventAndScheduleDelivery(unsigned long, unsigned char) + 118
35 CFNetwork 0x2d96c76e CoreStreamBase::_streamInterface_SignalEvent(unsigned long, CFStreamError const*) + 30
36 CFNetwork 0x2d96c70a SocketStream::dispatchSignalFromSocketCallbackUnlocked(SocketStreamSignalHolder*) + 50
37 CFNetwork 0x2d96c1ae SocketStream::socketCallback(__CFSocket*, unsigned long, __CFData const*, void const*) + 138
38 CFNetwork 0x2d96c0ea SocketStream::_SocketCallBack_stream(__CFSocket*, unsigned long, __CFData const*, void const*, void*) + 54
39 CoreFoundation 0x2dd46102 __CFSocketPerformV0 + 578
40 CoreFoundation 0x2dd43f24 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 12
41 CoreFoundation 0x2dd433ea __CFRunLoopDoSources0 + 202
42 CoreFoundation 0x2dd41bda __CFRunLoopRun + 626
43 CoreFoundation 0x2dcac53c CFRunLoopRunSpecific + 520
44 CoreFoundation 0x2dcac31e CFRunLoopRunInMode + 102
45 Foundation 0x2e6e764c +[NSURLConnection(Loader) _resourceLoadLoop:] + 316
46 Foundation 0x2e75cdc2 __NSThread__main__ + 1058
47 libsystem_pthread.dylib 0x38689c5a _pthread_body + 138
48 libsystem_pthread.dylib 0x38689bca _pthread_start + 98
49 libsystem_pthread.dylib 0x38687ccc thread_start + 4
Thread 7:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 8 name: com.apple.CFSocket.private
Thread 8:
0 libsystem_kernel.dylib 0x38623440 select$DARWIN_EXTSN + 20
1 CoreFoundation 0x2dd4745e __CFSocketManager + 482
2 libsystem_pthread.dylib 0x38689c5a _pthread_body + 138
3 libsystem_pthread.dylib 0x38689bca _pthread_start + 98
4 libsystem_pthread.dylib 0x38687ccc thread_start + 4
Thread 4 crashed with ARM Thread State (32-bit):
r0: 0x00000000 r1: 0x00000000 r2: 0x00000000 r3: 0x00002060
r4: 0x00000006 r5: 0x02826000 r6: 0x00000000 r7: 0x02825174
r8: 0x17ddfae0 r9: 0x00000001 r10: 0x30b5f763 r11: 0x00000000
ip: 0x00000148 sp: 0x02825168 lr: 0x3868aa53 pc: 0x386231fc
cpsr: 0x00000010
Crash log 3:
Incident Identifier: 09CD02C2-162E-40FB-8AA5-2F098D833D1C
CrashReporter Key: 369354cb12966b72d136b40418726dd923de7aae
Hardware Model: iPhone5,1
Process: HomeAutomation [679]
Path: /var/mobile/Applications/6F99E387-2530-4433-8DB8-0B657C4F9742/HomeAutomation.app/HomeAutomation
Identifier: com.carbon306.HomeAutomation
Version: 1.0 (1.0)
Code Type: ARM (Native)
Parent Process: launchd [1]
Date/Time: 2013-10-12 01:18:19.932 -0300
OS Version: iOS 7.0.2 (11A501)
Report Version: 104
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Subtype: KERN_INVALID_ADDRESS at 0x73746564
Triggered by Thread: 5
Thread 0:
0 libsystem_kernel.dylib 0x38610a84 mach_msg_trap + 20
1 libsystem_kernel.dylib 0x3861087c mach_msg + 36
2 CoreFoundation 0x2dd4355c __CFRunLoopServiceMachPort + 152
3 CoreFoundation 0x2dd41cc2 __CFRunLoopRun + 858
4 CoreFoundation 0x2dcac53c CFRunLoopRunSpecific + 520
5 CoreFoundation 0x2dcac31e CFRunLoopRunInMode + 102
6 GraphicsServices 0x329e32e6 GSEventRunModal + 134
7 UIKit 0x305631e0 UIApplicationMain + 1132
8 HomeAutomation 0x00073d48 main (main.m:16)
9 libdyld.dylib 0x3856cab4 start + 0
Thread 1:
0 libsystem_kernel.dylib 0x38610838 kevent64 + 24
1 libdispatch.dylib 0x3855f0d0 _dispatch_mgr_invoke + 228
2 libdispatch.dylib 0x3855963e _dispatch_mgr_thread + 34
Thread 2:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 3:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 4:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 5 Crashed:
0 libobjc.A.dylib 0x3807677a lookUpImpOrForward + 46
1 libobjc.A.dylib 0x3806f026 _class_lookupMethodAndLoadCache3 + 30
2 libobjc.A.dylib 0x3806edf6 _objc_msgSend_uncached + 22
3 libdispatch.dylib 0x38558100 _dispatch_call_block_and_release + 8
4 libdispatch.dylib 0x3855d7e0 _dispatch_root_queue_drain + 220
5 libdispatch.dylib 0x3855d9cc _dispatch_worker_thread2 + 52
6 libsystem_pthread.dylib 0x38687dfc _pthread_wqthread + 296
7 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 6 name: com.apple.NSURLConnectionLoader
Thread 6:
0 libsystem_kernel.dylib 0x38610a84 mach_msg_trap + 20
1 libsystem_kernel.dylib 0x3861087c mach_msg + 36
2 CoreFoundation 0x2dd4355c __CFRunLoopServiceMachPort + 152
3 CoreFoundation 0x2dd41c7c __CFRunLoopRun + 788
4 CoreFoundation 0x2dcac53c CFRunLoopRunSpecific + 520
5 CoreFoundation 0x2dcac31e CFRunLoopRunInMode + 102
6 Foundation 0x2e6e764c +[NSURLConnection(Loader) _resourceLoadLoop:] + 316
7 Foundation 0x2e75cdc2 __NSThread__main__ + 1058
8 libsystem_pthread.dylib 0x38689c5a _pthread_body + 138
9 libsystem_pthread.dylib 0x38689bca _pthread_start + 98
10 libsystem_pthread.dylib 0x38687ccc thread_start + 4
Thread 7 name: com.apple.CFSocket.private
Thread 7:
0 libsystem_kernel.dylib 0x38623440 select$DARWIN_EXTSN + 20
1 CoreFoundation 0x2dd4745e __CFSocketManager + 482
2 libsystem_pthread.dylib 0x38689c5a _pthread_body + 138
3 libsystem_pthread.dylib 0x38689bca _pthread_start + 98
4 libsystem_pthread.dylib 0x38687ccc thread_start + 4
Thread 8:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 5 crashed with ARM Thread State (32-bit):
r0: 0x73746564 r1: 0x30b5f763 r2: 0x17e3b980 r3: 0x00000001
r4: 0x30b5f763 r5: 0x30b40a4f r6: 0x00140c40 r7: 0x02837f54
r8: 0x00000000 r9: 0x00000001 r10: 0x00000001 r11: 0x00000000
ip: 0x3806f009 sp: 0x02837f30 lr: 0x3806f02b pc: 0x3807677a
cpsr: 0x80000030
Crash log 4:
Incident Identifier: B9DCE622-A962-4C0F-8653-E0B6EECFCC66
CrashReporter Key: 369354cb12966b72d136b40418726dd923de7aae
Hardware Model: iPhone5,1
Process: HomeAutomation [598]
Path: /var/mobile/Applications/6F99E387-2530-4433-8DB8-0B657C4F9742/HomeAutomation.app/HomeAutomation
Identifier: com.carbon306.HomeAutomation
Version: 1.0 (1.0)
Code Type: ARM (Native)
Parent Process: launchd [1]
Date/Time: 2013-10-12 00:57:58.928 -0300
OS Version: iOS 7.0.2 (11A501)
Report Version: 104
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Triggered by Thread: 4
Last Exception Backtrace:
0 CoreFoundation 0x2dd78e86 __exceptionPreprocess + 126
1 libobjc.A.dylib 0x380736c2 objc_exception_throw + 34
2 CoreFoundation 0x2dd7c7b2 -[NSObject(NSObject) doesNotRecognizeSelector:] + 198
3 CoreFoundation 0x2dd7b0b2 ___forwarding___ + 702
4 CoreFoundation 0x2dcc9e94 __forwarding_prep_0___ + 20
5 libdispatch.dylib 0x385580fe _dispatch_call_block_and_release + 6
6 libdispatch.dylib 0x3855d7e0 _dispatch_root_queue_drain + 220
7 libdispatch.dylib 0x3855d9cc _dispatch_worker_thread2 + 52
8 libsystem_pthread.dylib 0x38687dfa _pthread_wqthread + 294
9 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 0:
0 libsystem_kernel.dylib 0x38610a84 mach_msg_trap + 20
1 libsystem_kernel.dylib 0x3861087c mach_msg + 36
2 CoreFoundation 0x2dd4355c __CFRunLoopServiceMachPort + 152
3 CoreFoundation 0x2dd41cc2 __CFRunLoopRun + 858
4 CoreFoundation 0x2dcac53c CFRunLoopRunSpecific + 520
5 CoreFoundation 0x2dcac31e CFRunLoopRunInMode + 102
6 GraphicsServices 0x329e32e6 GSEventRunModal + 134
7 UIKit 0x305631e0 UIApplicationMain + 1132
8 HomeAutomation 0x00019ca0 main (main.m:16)
9 libdyld.dylib 0x3856cab4 start + 0
Thread 1:
0 libsystem_kernel.dylib 0x38610838 kevent64 + 24
1 libdispatch.dylib 0x3855f0d0 _dispatch_mgr_invoke + 228
2 libdispatch.dylib 0x3855963e _dispatch_mgr_thread + 34
Thread 2:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 3:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 4 Crashed:
0 libsystem_kernel.dylib 0x386231fc __pthread_kill + 8
1 libsystem_pthread.dylib 0x3868aa4e pthread_kill + 54
2 libsystem_c.dylib 0x385d4028 abort + 72
3 libc++abi.dylib 0x37a2298a abort_message + 70
4 libc++abi.dylib 0x37a3b6e2 default_terminate_handler() + 250
5 libobjc.A.dylib 0x38073936 _objc_terminate() + 190
6 libc++abi.dylib 0x37a391b0 std::__terminate(void (*)()) + 76
7 libc++abi.dylib 0x37a38a04 __cxa_throw + 112
8 libobjc.A.dylib 0x38073796 objc_exception_throw + 246
9 CoreFoundation 0x2dd7c7b2 -[NSObject(NSObject) doesNotRecognizeSelector:] + 198
10 CoreFoundation 0x2dd7b0b2 ___forwarding___ + 702
11 CoreFoundation 0x2dcc9e94 __forwarding_prep_0___ + 20
12 libdispatch.dylib 0x38558100 _dispatch_call_block_and_release + 8
13 libdispatch.dylib 0x3855d7e0 _dispatch_root_queue_drain + 220
14 libdispatch.dylib 0x3855d9cc _dispatch_worker_thread2 + 52
15 libsystem_pthread.dylib 0x38687dfc _pthread_wqthread + 296
16 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 5:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 6:
0 libsystem_kernel.dylib 0x38623c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x38687e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x38687cc0 start_wqthread + 4
Thread 7 name: com.apple.NSURLConnectionLoader
Thread 7:
0 libsystem_kernel.dylib 0x38610a84 mach_msg_trap + 20
1 libsystem_kernel.dylib 0x3861087c mach_msg + 36
2 CoreFoundation 0x2dd4355c __CFRunLoopServiceMachPort + 152
3 CoreFoundation 0x2dd41c7c __CFRunLoopRun + 788
4 CoreFoundation 0x2dcac53c CFRunLoopRunSpecific + 520
5 CoreFoundation 0x2dcac31e CFRunLoopRunInMode + 102
6 Foundation 0x2e6e764c +[NSURLConnection(Loader) _resourceLoadLoop:] + 316
7 Foundation 0x2e75cdc2 __NSThread__main__ + 1058
8 libsystem_pthread.dylib 0x38689c5a _pthread_body + 138
9 libsystem_pthread.dylib 0x38689bca _pthread_start + 98
10 libsystem_pthread.dylib 0x38687ccc thread_start + 4
Thread 8 name: com.apple.CFSocket.private
Thread 8:
0 libsystem_kernel.dylib 0x38623440 select$DARWIN_EXTSN + 20
1 CoreFoundation 0x2dd4745e __CFSocketManager + 482
2 libsystem_pthread.dylib 0x38689c5a _pthread_body + 138
3 libsystem_pthread.dylib 0x38689bca _pthread_start + 98
4 libsystem_pthread.dylib 0x38687ccc thread_start + 4
Thread 4 crashed with ARM Thread State (32-bit):
r0: 0x00000000 r1: 0x00000000 r2: 0x00000000 r3: 0x00002060
r4: 0x00000006 r5: 0x0275c000 r6: 0x00000000 r7: 0x0275b174
r8: 0x165970a0 r9: 0x00000001 r10: 0x30b5f763 r11: 0x00000000
ip: 0x00000148 sp: 0x0275b168 lr: 0x3868aa53 pc: 0x386231fc
cpsr: 0x00000010
Also I think it has something to do with this method: - [UIManagedDocument openWithCompletionHandler:] because if I comment out this line (used to open the document when document.documentState == UIDocumentStateClosed), the crash stops.
Just to make it easier, that UIManagedDocument Singleton Code openWithCompletionHandler called twice and crashes is not the problem, because - [UIManagedDocument openWithCompletionHandler:] is not being called twice. Also, just to be sure, I did try that solution, and didn't change anything.
I'm sorry for the amount of information, but I did try to write here only the most relevant ones, also only one of each type of error that I found.
Thanks for the help.
Below links explains how to symbolicate the crash logs. it sounds useful.
from apples documentation :
https://developer.apple.com/library/ios/technotes/tn2151/_index.html
from raywanderlitch's explanation :
http://www.raywenderlich.com/23704/demystifying-ios-application-crash-logs
User contributions licensed under CC BY-SA 3.0