Strange crash on iOS 4.3.5 - objective-c

SIGSEGV SEGV_ACCERR
Here's stacktraces (according to crittercism)
Crashed thread:
0 libobjc.A.dylib 0x33b75c98 objc_msgSend + 15
1 Foundation 0x34ce5389 -[NSThread main] + 44
2 Foundation 0x34d575cd __NSThread__main__ + 972
3 libsystem_c.dylib 0x34600311 _pthread_start + 248
Other threads:
0 libsystem_kernel.dylib 0x345c4c00 mach_msg_trap + 20
1 CoreFoundation 0x368f62bf __CFRunLoopServiceMachPort + 94
2 CoreFoundation 0x368f8569 __CFRunLoopRun + 356
3 CoreFoundation 0x36888ec3 CFRunLoopRunSpecific + 230
4 CoreFoundation 0x36888dcb CFRunLoopRunInMode + 58
5 GraphicsServices 0x3604241f GSEventRunModal + 114
6 GraphicsServices 0x360424cb GSEventRun + 62
7 UIKit 0x35732d69 -[UIApplication _run] + 404
8 UIKit 0x35730807 UIApplicationMain + 670
9 (app name) 0x3b97 main (main.m:8)
Thread: Unknown Name
0 libsystem_kernel.dylib 0x345c7fbc kevent + 24
1 libdispatch.dylib 0x33799041 _dispatch_queue_invoke + 92
2 libdispatch.dylib 0x337985f1 _dispatch_worker_thread2 + 192
3 libsystem_c.dylib 0x34601591 _pthread_wqthread + 264
Thread: Unknown Name
0 libsystem_kernel.dylib 0x345c4c00 mach_msg_trap + 20
1 CoreFoundation 0x368f62bf __CFRunLoopServiceMachPort + 94
2 CoreFoundation 0x368f8569 __CFRunLoopRun + 356
3 CoreFoundation 0x36888ec3 CFRunLoopRunSpecific + 230
4 CoreFoundation 0x36888dcb CFRunLoopRunInMode + 58
5 WebCore 0x36051285 _ZL12RunWebThreadPv + 388
6 libsystem_c.dylib 0x34600311 _pthread_start + 248
Thread: Unknown Name
0 libsystem_kernel.dylib 0x345c4c00 mach_msg_trap + 20
1 CoreFoundation 0x368f62bf __CFRunLoopServiceMachPort + 94
2 CoreFoundation 0x368f8569 __CFRunLoopRun + 356
3 CoreFoundation 0x36888ec3 CFRunLoopRunSpecific + 230
4 CoreFoundation 0x36888dcb CFRunLoopRunInMode + 58
5 Foundation 0x34cf27fd +[NSURLConnection(NSURLConnectionReallyInternal) _resourceLoadLoop:] + 212
6 Foundation 0x34ce5389 -[NSThread main] + 44
7 Foundation 0x34d575cd __NSThread__main__ + 972
8 libsystem_c.dylib 0x34600311 _pthread_start + 248
Thread: Unknown Name
0 libsystem_kernel.dylib 0x345c4c00 mach_msg_trap + 20
1 CoreFoundation 0x368f62bf __CFRunLoopServiceMachPort + 94
2 CoreFoundation 0x368f8569 __CFRunLoopRun + 356
3 CoreFoundation 0x36888ec3 CFRunLoopRunSpecific + 230
4 CoreFoundation 0x368cb6d9 CFRunLoopRun + 48
5 (app name) 0x0001e04b +[ASIHTTPRequest runRequests] (ASIHTTPRequest.m:4791)
6 Foundation 0x34ce5389 -[NSThread main] + 44
7 Foundation 0x34d575cd __NSThread__main__ + 972
8 libsystem_c.dylib 0x34600311 _pthread_start + 248
Thread: Unknown Name
0 libsystem_kernel.dylib 0x345c6c60 __select + 20
1 libsystem_c.dylib 0x34600311 _pthread_start + 248
Thread: Unknown Name
0 libsystem_kernel.dylib 0x345c6d18 __semwait_signal + 24
1 libsystem_c.dylib 0x345ceeb9 pthread_cond_wait + 32
2 CoreMedia 0x313578fb WaitOnCondition + 10
3 CoreMedia 0x31357841 FigSemaphoreWaitRelative + 72
4 MediaToolbox 0x3336ba6b fpa_AsyncMovieControlThread + 54
5 CoreMedia 0x313754e3 figThreadMain + 162
6 libsystem_c.dylib 0x34600311 _pthread_start + 248
Thread: Unknown Name
0 libsystem_kernel.dylib 0x345c4c00 mach_msg_trap + 20
1 CoreFoundation 0x368f62bf __CFRunLoopServiceMachPort + 94
2 CoreFoundation 0x368f8569 __CFRunLoopRun + 356
3 CoreFoundation 0x36888ec3 CFRunLoopRunSpecific + 230
4 CoreFoundation 0x36888dcb CFRunLoopRunInMode + 58
5 MapKit 0x313a345d _ZN16TileCachePrivate14runCacheThreadEv + 280
6 MapKit 0x313a3341 _ZL15_runCacheThreadPv + 8
7 libsystem_c.dylib 0x34600311 _pthread_start + 248
Thread: Unknown Name
0 libsystem_kernel.dylib 0x345c6d18 __semwait_signal + 24
1 libsystem_c.dylib 0x345ceeb9 pthread_cond_wait + 32
2 QuartzCore 0x30dcb737 _ZN2CA13DispatchGroup6threadEPv + 90
3 QuartzCore 0x30de583d thread_fun + 16
4 libsystem_c.dylib 0x34600311 _pthread_start + 248
Thread: Unknown Name
0 libsystem_kernel.dylib 0x345c4c00 mach_msg_trap + 20
1 CoreFoundation 0x368f62bf __CFRunLoopServiceMachPort + 94
2 CoreFoundation 0x368f8569 __CFRunLoopRun + 356
3 CoreFoundation 0x36888ec3 CFRunLoopRunSpecific + 230
4 CoreFoundation 0x36888dcb CFRunLoopRunInMode + 58
5 MapKit 0x313ae215 +[NSThread(MKAdditions) _mapkit_runThread:] + 340
6 Foundation 0x34ce5389 -[NSThread main] + 44
7 Foundation 0x34d575cd __NSThread__main__ + 972
8 libsystem_c.dylib 0x34600311 _pthread_start + 248
Thread: Unknown Name
0 libsystem_kernel.dylib 0x345c73ec __workq_kernreturn + 8
Thread: Unknown Name
0 libsystem_kernel.dylib 0x345c73ec __workq_kernreturn + 8
Will be grateful for any suggestions how to fix this crash.

This crash happens because of a memory leak or zombie object. You are releasing an object which later on is accessed on the main thread. Best way to track this down is to use instruments leaks detection or NSZombie.
The leak could be anywhere in your app, the crash report can't give you a lot of help on that.

Related

libobjc.A.dylib crashed? How can I debug?

Thread 0:
0 libobjc.A.dylib 0x30d4af80 objc_msgSend + 32
1 CoreUI 0x28dce2b9 -[CUIMutableStructuredThemeStore imagesWithName:] + 117
2 UIKit 0x26d26f49 -[UIImageAsset unregisterImageWithTraitCollection:] + 133
3 UIKit 0x26d27743 -[_UIPathLazyImageAsset _clearResolvedImageResources] + 171
4 UIKit 0x26c7997d -[_UIAssetManager _clearCachedResources:] + 225
5 CoreFoundation 0x2316cf15 __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 13
6 CoreFoundation 0x230c7e4d _CFXNotificationPost + 1801
7 Foundation 0x23dfce61 -[NSNotificationCenter postNotificationName:object:userInfo:] + 77
8 Foundation 0x23e019df -[NSNotificationCenter postNotificationName:object:] + 31
9 UIKit 0x268c0143 -[UIApplication _performMemoryWarning] + 139
10 libdispatch.dylib 0x3129f40f _dispatch_client_callout + 23
11 libdispatch.dylib 0x312b4709 _dispatch_source_latch_and_call + 621
12 libdispatch.dylib 0x312adf3d _dispatch_source_invoke$VARIANT$mp + 213
13 libdispatch.dylib 0x312aa035 _dispatch_main_queue_callback_4CF$VARIANT$mp + 329
14 CoreFoundation 0x2317a631 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 9
15 CoreFoundation 0x23178d51 __CFRunLoopRun + 1513
16 CoreFoundation 0x230c5b31 CFRunLoopRunSpecific + 477
17 CoreFoundation 0x230c5943 CFRunLoopRunInMode + 107
18 GraphicsServices 0x2a47a051 GSEventRunModal + 137
19 UIKit 0x266b7f21 UIApplicationMain + 1441
20 BaiduHD 0x0094e2a9 main (main.m:17)
21 libdyld.dylib 0x312daaaf start + 3
Thread 1:
0 libsystem_kernel.dylib 0x3138c2c8 kevent64 + 24
1 libdispatch.dylib 0x312aeb7b _dispatch_mgr_thread$VARIANT$mp + 39
Thread 2:
0 libsystem_kernel.dylib 0x3138c580 semaphore_timedwait_trap + 8
1 BaiduHD 0x0068c7b5 __23-[CrabANRMonitor start]_block_invoke (CrabANRMonitor.m:84)
2 libdispatch.dylib 0x3129f423 _dispatch_call_block_and_release + 11
3 libdispatch.dylib 0x312ab2db _dispatch_root_queue_drain + 851
4 libdispatch.dylib 0x312ac1fb _dispatch_worker_thread3 + 107
5 libsystem_pthread.dylib 0x3141ce25 _pthread_wqthread + 669
6 libsystem_pthread.dylib 0x3141cb78 start_wqthread + 8
Thread 3:
0 libsystem_kernel.dylib 0x3138c518 mach_msg_trap + 20
1 CoreFoundation 0x2317a59b __CFRunLoopServiceMachPort + 147
2 CoreFoundation 0x23178b61 __CFRunLoopRun + 1017
3 CoreFoundation 0x230c5b31 CFRunLoopRunSpecific + 477
4 CoreFoundation 0x230c5943 CFRunLoopRunInMode + 107
5 WebCore 0x2e729819 RunWebThread() + 417
6 libsystem_pthread.dylib 0x3141ee67 _pthread_body + 139
7 libsystem_pthread.dylib 0x3141eddb _pthread_start + 119
8 libsystem_pthread.dylib 0x3141cb84 thread_start + 8
Thread 4:
0 libsystem_kernel.dylib 0x3138c518 mach_msg_trap + 20
1 CoreFoundation 0x2317a59b __CFRunLoopServiceMachPort + 147
2 CoreFoundation 0x23178b61 __CFRunLoopRun + 1017
3 CoreFoundation 0x230c5b31 CFRunLoopRunSpecific + 477
4 CoreFoundation 0x230c5943 CFRunLoopRunInMode + 107
5 Foundation 0x23e028f1 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 265
6 Foundation 0x23e50d65 -[NSRunLoop(NSRunLoop) run] + 81
7 BaiduHD 0x00c1d8bf +[AFURLConnectionOperation networkRequestThreadEntryPoint:] (AFURLConnectionOperation.m:169)
8 Foundation 0x23ec793b __NSThread__main__ + 1119
9 libsystem_pthread.dylib 0x3141ee67 _pthread_body + 139
10 libsystem_pthread.dylib 0x3141eddb _pthread_start + 119
11 libsystem_pthread.dylib 0x3141cb84 thread_start + 8
Thread 5:
0 libsystem_kernel.dylib 0x3138c518 mach_msg_trap + 20
1 CoreFoundation 0x2317a59b __CFRunLoopServiceMachPort + 147
2 CoreFoundation 0x23178b61 __CFRunLoopRun + 1017
3 CoreFoundation 0x230c5b31 CFRunLoopRunSpecific + 477
4 CoreFoundation 0x230c5943 CFRunLoopRunInMode + 107
5 CFNetwork 0x22c7a78f +NSURLConnection(Loader) _resourceLoadLoop:] + 487
6 Foundation 0x23ec793b __NSThread__main__ + 1119
7 libsystem_pthread.dylib 0x3141ee67 _pthread_body + 139
8 libsystem_pthread.dylib 0x3141eddb _pthread_start + 119
9 libsystem_pthread.dylib 0x3141cb84 thread_start + 8
Thread 6:
0 libsystem_kernel.dylib 0x313a008c select$DARWIN_EXTSN + 20
1 libsystem_pthread.dylib 0x3141ee67 _pthread_body + 139
2 libsystem_pthread.dylib 0x3141eddb _pthread_start + 119
3 libsystem_pthread.dylib 0x3141cb84 thread_start + 8
Thread 7:
0 libsystem_kernel.dylib 0x313a09cc __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x3141cb78 start_wqthread + 8
Thread 8:
0 libsystem_kernel.dylib 0x3138c518 mach_msg_trap + 20
1 CoreFoundation 0x2317a59b __CFRunLoopServiceMachPort + 147
2 CoreFoundation 0x23178b61 __CFRunLoopRun + 1017
3 CoreFoundation 0x230c5b31 CFRunLoopRunSpecific + 477
4 CoreFoundation 0x230c5943 CFRunLoopRunInMode + 107
5 BaiduHD 0x00c40917 +[ASIHTTPRequest runRequests] (ASIHTTPRequest.m:4798)
6 Foundation 0x23ec793b __NSThread__main__ + 1119
7 libsystem_pthread.dylib 0x3141ee67 _pthread_body + 139
8 libsystem_pthread.dylib 0x3141eddb _pthread_start + 119
9 libsystem_pthread.dylib 0x3141cb84 thread_start + 8
Thread 9:
0 libsystem_kernel.dylib 0x313a09cc __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x3141cb78 start_wqthread + 8
Thread 10:
0 libsystem_kernel.dylib 0x3138c518 mach_msg_trap + 20
1 CoreFoundation 0x2317a59b _CFRunLoopServiceMachPort + 147
2 CoreFoundation 0x23178b61 __CFRunLoopRun + 1017
3 CoreFoundation 0x230c5b31 CFRunLoopRunSpecific + 477
4 CoreFoundation 0x230c5943 CFRunLoopRunInMode + 107
5 libAVFAudio.dylib 0x21de93ed GenericRunLoopThread::Entry() + 133
6 libAVFAudio.dylib 0x21ddb8e7 CAPThread::Entry() + 195
7 libsystem_pthread.dylib 0x3141ee67 _pthread_body + 139
8 libsystem_pthread.dylib 0x3141eddb _pthread_start + 119
9 libsystem_pthread.dylib 0x3141cb84 thread_start + 8
Thread 11:
0 libsystem_kernel.dylib 0x3138c518 mach_msg_trap + 20
1 CoreFoundation 0x2317a59b __CFRunLoopServiceMachPort + 147
2 CoreFoundation 0x23178b61 __CFRunLoopRun + 1017
3 CoreFoundation 0x230c5b31 RunLoopRunSpecific + 477
4 CoreFoundation 0x2310f4fb CFRunLoopRun + 99
5 CoreMotion 0x239ccd23 CLSF_thorntonUpdate_6x6 + 47379
6 libsystem_pthread.dylib 0x3141ee67 _pthread_body + 139
7 libsystem_pthread.dylib 0x3141eddb _pthread_start + 119
8 libsystem_pthread.dylib 0x3141cb84 thread_start + 8
Thread 12:
0 libsystem_kernel.dylib 0x313a09cc __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x3141cb78 start_wqthread + 8
Thread 13:
libsystem_kernel.dylib 0x3138c518 mach_msg_trap + 20
1 CoreFoundation 0x2317a59b __CFRunLoopServiceMachPort + 147
2 CoreFoundation 0x23178b61 __CFRunLoopRun + 1017
3 CoreFoundation 0x230c5b31 CFRunLoopRunSpecific + 477
4 CoreFoundation 0x230c5943 CFRunLoopRunInMode + 107
5 Foundation 0x23e028f1 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 265
6 Foundation 0x23e50d65 -[NSRunLoop(NSRunLoop) run] + 81
7 BaiduHD 0x0067a365 +[CrabURLConnectionOperation networkRequestThreadEntryPoint:] (CrabURLConnectionOperation.m:152)
8 Foundation 0x23ec793b __NSThread__main__ + 1119
9 libsystem_pthread.dylib 0x3141ee67 _pthread_body + 139
10 libsystem_pthread.dylib 0x3141eddb _pthread_start + 119
11 libsystem_pthread.dylib 0x3141cb84 thread_start + 8
Thread 14:
0 libsystem_kernel.dylib 0x3139fb38 __psynch_cvwait + 24
1 libsystem_pthread.dylib 0x3141f2b1 pthread_cond_wait + 41
2 libc++.1.dylib 0x30508fa9 std::__1::condition_variable::wait() + 37
3 JavaScriptCore 0x24388f3b JSC::BlockAllocator::blockFreeingThreadMain() + 215
4 JavaScriptCore 0x243853ef WTF::wtfThreadEntryPoint() + 15
5 libsystem_pthread.dylib 0x3141ee67 _pthread_body + 139
6 libsystem_pthread.dylib 0x3141eddb _pthread_start + 119
7 libsystem_pthread.dylib 0x3141cb84 thread_start + 8
Thread 15:
0 libsystem_kernel.dylib 0x3139fb38 __psynch_cvwait + 24
1 libsystem_pthread.dylib 0x3141f2b1 pthread_cond_wait + 41
2 libc++.1.dylib 0x30508fa9 std::__1::condition_variable::wait() + 37
3 JavaScriptCore 0x2454db05 JSC::GCThread::waitForNextPhase() + 105
4 JavaScriptCore 0x2454db69 JSC::GCThread::gcThreadMain() + 53
5 JavaScriptCore 0x243853ef WTF::wtfThreadEntryPoint() + 15
libsystem_pthread.dylib 0x3141ee67 _pthread_body + 139
7 libsystem_pthread.dylib 0x3141eddb _pthread_start + 119
8 libsystem_pthread.dylib 0x3141cb84 thread_start + 8
Thread 16:
0 libsystem_kernel.dylib 0x313a09cc __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x3141cb78 start_wqthread + 8
Thread 17:
0 libsystem_kernel.dylib 0x313a09cc __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x3141cb78 start_wqthread + 8
Thread 18 Crashed:
0 libobjc.A.dylib 0x30d4af66 objc_msgSend + 6
1 libcache.dylib 0x312380a5 _value_entry_remove + 141
2 libcache.dylib 0x31236beb _entry_evict + 131
3 libcache.dylib 0x31237d99 _evict_last + 145
4 libcache.dylib 0x31237f2d _cache_enforce_limits + 101
5 libcache.dylib 0x31237eb1 ___cache_handle_memory_pressure_event_block_invoke + 49
6 libdispatch.dylib 0x3129f423 _dispatch_call_block_and_release + 11
7 libdispatch.dylib 0x312ab2db _dispatch_root_queue_drain + 851
8 libdispatch.dylib 0x312ac1fb _dispatch_worker_thread3 + 107
9 libsystem_pthread.dylib 0x3141ce25 _pthread_wqthread + 669
10 libsystem_pthread.dylib 0x3141cb78 start_wqthread + 8
Thread 19:
0 libsystem_kernel.dylib 0x313a09cc __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x3141cb78 start_wqthread + 8
Thread 20:
0 libsystem_kernel.dylib 0x3139fb38 __psynch_cvwait + 24
1 libsystem_pthread.dylib 0x3141f2f1 pthread_cond_timedwait + 45
2 libc++.1.dylib 0x30509079 s::__1::condition_variable::__do_timed_wait() + 185
3 JavaScriptCore 0x244ad791 std::__1::condition_variable::wait_for >() + 201
4 JavaScriptCore 0x24388ebb JSC::BlockAllocator::blockFreeingThreadMain() + 87
5 JavaScriptCore 0x243853ef WTF::wtfThreadEntryPoint() + 15
6 libsystem_pthread.dylib 0x3141ee67 _pthread_body + 139
7 libsystem_pthread.dylib 0x3141eddb _pthread_start + 119
8 libsystem_pthread.dylib 0x3141cb84 thread_start + 8
Thread 21:
0 libsystem_kernel.dylib 0x3139fb38 __psynch_cvwait + 24
1 libsystem_pthread.dylib 0x3141f2b1 pthread_cond_wait + 41
2 libc++.1.dylib 0x30508fa9 std::__1::condition_variable::wait() + 37
3 JavaScriptCore 0x2454db05 JSC::GCThread::waitForNextPhase() + 105
4 JavaScriptCore 0x2454db69 JSC::GCThread::gcThreadMain() + 53
5 JavaScriptCore 0x243853ef WTF::wtfThreadEntryPoint() + 15
6 libsystem_pthread.dylib 0x3141ee67 _pthread_body + 139
7 libsystem_pthread.dylib 0x3141eddb _pthread_start + 119
8 libsystem_pthread.dylib 0x3141cb84 thread_start + 8
Thread 22:
0 libsystem_kernel.dylib 0x3138c518 mach_msg_trap + 20
1 CoreFoundation 0x2317a59b __CFRunLoopServiceMachPort + 147
2 CoreFoundation 0x23178b61 __CFRunLoopRun + 1017
3 CoreFoundation 0x230c5b31 CFRunLoopRunSpecific + 477
CoreFoundation 0x230c5943 CFRunLoopRunInMode + 107
5 WebCore 0x2e752b55 WebCore::runLoaderThread() + 293
6 JavaScriptCore 0x243853ef WTF::wtfThreadEntryPoint() + 15
7 libsystem_pthread.dylib 0x3141ee67 _pthread_body + 139
8 libsystem_pthread.dylib 0x3141eddb _pthread_start + 119
9 libsystem_pthread.dylib 0x3141cb84 thread_start + 8
Thread 18 crashed with ARM Thread State:
pc: 0x30d4af66 r7: 0x05039f10 sp: 0x05039efc r0: 0x31773a5d
r1: 0x233d6fea r2: 0x177246d0 r3: 0x18845e90 r4: 0x18845e90
r5: 0x177246d0 r6: 0x31773a5d r8: 0x00000000 r9: 0xa123a48f
r10: 0x316a6fa4 r11: 0x1773a518 ip: 0x316837f0 lr: 0x231f4c29
cpsr: 0x20000030
Thread 18 crashed.
UIWebView maybe load this url https://www.baidu.com/s?bundleid=com.baidu.BaiduHD&ie=utf-8&wd=%E5%9B%BD%E4%BA%A7psp4000&dsp=ipad&tn=SE_baiduipadhd2_22k1x757&rn=10&rsv_baiduhdpage=4&openudid=8ae020abea3190f77b90d055201d5886b5c03a29&hsug_mtype=0
This is the collapse of the log information. I did not replicate the collapse. Can you give me some advice about how to debug?

How to debug CoreFoundation Crash run_animation_callbacks

I do not know how I can use the following crash report from crashlytics to narrow down the source of the crash.
All I understand is that it has something to do with CoreFoundation, but what exactly is the crash? And where in my code is it happening?
Is a CAAnimation Delegate? Or perhaps I did not remove and observer from NSNotifications?
Any ideas?
Crashed: com.apple.main-thread SIGABRT ABORT at 0x39a5cdf0
Thread : Crashed: com.apple.main-thread
0 libsystem_kernel.dylib 0x39a5cdf0 __pthread_kill + 8
1 libsystem_pthread.dylib 0x39addc97 pthread_kill + 62
2 libsystem_c.dylib 0x399fb939 abort + 76
3 libc++abi.dylib 0x38bfabbd __cxa_bad_cast
4 libc++abi.dylib 0x38c1466f default_terminate_handler() + 266
5 libobjc.A.dylib 0x393eef11 _objc_terminate() + 192
6 libc++abi.dylib 0x38c11def std::__terminate(void (*)()) + 78
7 libc++abi.dylib 0x38c115b1 __cxxabiv1::exception_cleanup_func(_Unwind_Reason_Code, _Unwind_Exception*)
8 libobjc.A.dylib 0x393eed4b objc_exception_throw + 250
9 CoreFoundation 0x2b4975fd __methodDescriptionForSelector
10 CoreFoundation 0x2b4954d9 ___forwarding___ + 712
11 CoreFoundation 0x2b3c49d8 _CF_forwarding_prep_0 + 24
12 QuartzCore 0x2e4eeff3 CA::Layer::run_animation_callbacks(void*) + 150
13 libdispatch.dylib 0x39958c6f _dispatch_client_callout + 22
14 libdispatch.dylib 0x39964553 _dispatch_main_queue_callback_4CF$VARIANT$mp + 1322
15 CoreFoundation 0x2b457889 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 8
16 CoreFoundation 0x2b455fa9 __CFRunLoopRun + 1512
17 CoreFoundation 0x2b3a19a1 CFRunLoopRunSpecific + 476
18 CoreFoundation 0x2b3a17b3 CFRunLoopRunInMode + 106
19 GraphicsServices 0x32b531a9 GSEventRunModal + 136
20 UIKit 0x2eb2c695 UIApplicationMain + 1440

EXC_BAD_ACCESS (SIGSEGV) and KERN_INVALID_ADDRESS

This issue is getting on my nerves. Please see the crash report and help. In iOS 6 app is working fine. I am performing some operations. After 30 operations are completed I am experiencing this crash. This number can go till 20 also or 1 also. Attaching crash log with this. All the experts please help.
Incident Identifier: E863E717-DE21-4BD0-A203-32E9D4648869
CrashReporter Key: b7fe8726c57b6cc93687be0e904625ecf3813fb9
Hardware Model: iPad2,5
Process: mobile [3833]
Path:
Identifier:
Version:
Code Type: ARM (Native)
Parent Process: launchd [1]
Date/Time: 2014-06-01 17:07:33.679 +0530
OS Version: iOS 7.0.6 (11B651)
Report Version: 104
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Subtype: KERN_INVALID_ADDRESS at 0x1e2d1f28
Triggered by Thread: 0
Thread 0 Crashed:
0 libobjc.A.dylib 0x38e79b26 objc_msgSend + 6
1 CoreFoundation 0x2e618650 CFRelease + 552
2 CoreFoundation 0x2e626702 -[__NSDictionaryI dealloc] + 114
3 libobjc.A.dylib 0x38e89b06 objc_object::sidetable_release(bool) + 170
4 libobjc.A.dylib 0x38e7b002 (anonymous namespace)::AutoreleasePoolPage::pop(void*) + 354
5 CoreFoundation 0x2e61b97c _CFAutoreleasePoolPop + 12
6 Foundation 0x2f00385c -[NSAutoreleasePool release] + 116
7 CoreFoundation 0x2e6b3180 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 12
8 CoreFoundation 0x2e6b264e __CFRunLoopDoSources0 + 202
9 CoreFoundation 0x2e6b0e42 __CFRunLoopRun + 618
10 CoreFoundation 0x2e61bc22 CFRunLoopRunSpecific + 518
11 CoreFoundation 0x2e61ba06 CFRunLoopRunInMode + 102
12 Foundation 0x2f0093d6 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 250
13 mobile 0x001704d0 -[VFIPinpad waitForACK] (VFIPinpad.m:2876)
14 mobile 0x00174cd8 -[VFIPinpad sendDataCommand:calcLRC:] (VFIPinpad.m:3716)
15 mobile 0x0017a46a -[VFIPinpad setROSParams:threshold:target:targetPercent:] (VFIPinpad.m:4702)
16 mobile 0x0020d5a4 -[VFIPWLm startTransaction:origAmount:finalAmount:surcharge:invoice:discount:promocode:chequeData:AVSAddress:AVSPostcode:email:refTransactionID:gpsLatitude:gpsLongitude:merchID:terminalID:allowRefundSystemByID:status:statusMsg:tranID:authCode:totalCharge:signatureRequired:voiceAuthPhone:merchantID:tipAmount:receiptData:cardScheme:] (VFIPWLm.m:2840)
17 mobile 0x00064df0 -[MainViewController startTran] (MainViewController.m:1918)
18 mobile 0x00077dac -[MainViewController showView] (MainViewController.m:3359)
19 mobile 0x00084d14 -[MainViewController sc8Next] (MainViewController.m:4674)
20 UIKit 0x30e8f70e -[UIApplication sendAction:to:from:forEvent:] + 86
21 UIKit 0x30e8f6ae -[UIApplication sendAction:toTarget:fromSender:forEvent:] + 26
22 UIKit 0x30e8f68c -[UIControl sendAction:to:forEvent:] + 40
23 UIKit 0x30e7b11a -[UIControl _sendActionsForEvents:withEvent:] + 370
24 UIKit 0x30e8f102 -[UIControl touchesEnded:withEvent:] + 586
25 UIKit 0x30e8edd4 -[UIWindow _sendTouchesForEvent:] + 524
26 UIKit 0x30e89e60 -[UIWindow sendEvent:] + 828
27 UIKit 0x30e5f798 -[UIApplication sendEvent:] + 192
28 UIKit 0x30e5df9e _UIApplicationHandleEventQueue + 7094
29 CoreFoundation 0x2e6b3180 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 12
30 CoreFoundation 0x2e6b264e __CFRunLoopDoSources0 + 202
31 CoreFoundation 0x2e6b0e42 __CFRunLoopRun + 618
32 CoreFoundation 0x2e61bc22 CFRunLoopRunSpecific + 518
33 CoreFoundation 0x2e61ba06 CFRunLoopRunInMode + 102
34 GraphicsServices 0x3330f27e GSEventRunModal + 134
35 UIKit 0x30ebf044 UIApplicationMain + 1132
36 mobile 0x00054ae0 main (main.m:16)
37 libdyld.dylib 0x39386ab4 start + 0
Thread 1:
0 libsystem_kernel.dylib 0x3942a83c kevent64 + 24
1 libdispatch.dylib 0x3936b210 _dispatch_mgr_invoke + 228
2 libdispatch.dylib 0x3936af96 _dispatch_mgr_thread$VARIANT$mp + 34
Thread 2 name: WebThread
Thread 2:
0 libsystem_kernel.dylib 0x3942aa8c mach_msg_trap + 20
1 libsystem_kernel.dylib 0x3942a888 mach_msg + 44
2 CoreFoundation 0x2e6b27be __CFRunLoopServiceMachPort + 150
3 CoreFoundation 0x2e6b0ee4 __CFRunLoopRun + 780
4 CoreFoundation 0x2e61bc22 CFRunLoopRunSpecific + 518
5 CoreFoundation 0x2e61ba06 CFRunLoopRunInMode + 102
6 WebCore 0x36829266 RunWebThread(void*) + 414
7 libsystem_pthread.dylib 0x394a5c1a _pthread_body + 138
8 libsystem_pthread.dylib 0x394a5b8a _pthread_start + 98
9 libsystem_pthread.dylib 0x394a3c8c thread_start + 4
Thread 3:
0 libsystem_kernel.dylib 0x3942aa8c mach_msg_trap + 20
1 libsystem_kernel.dylib 0x3942a888 mach_msg + 44
2 CoreFoundation 0x2e6b27be __CFRunLoopServiceMachPort + 150
3 CoreFoundation 0x2e6b0ee4 __CFRunLoopRun + 780
4 CoreFoundation 0x2e61bc22 CFRunLoopRunSpecific + 518
5 CoreFoundation 0x2e61ba06 CFRunLoopRunInMode + 102
6 libAVFAudio.dylib 0x2d69e584 GenericRunLoopThread::Entry(void*) + 124
7 libAVFAudio.dylib 0x2d69299c CAPThread::Entry(CAPThread*) + 176
8 libsystem_pthread.dylib 0x394a5c1a _pthread_body + 138
9 libsystem_pthread.dylib 0x394a5b8a _pthread_start + 98
10 libsystem_pthread.dylib 0x394a3c8c thread_start + 4
Thread 4 name: com.apple.CFSocket.private
Thread 4:
0 libsystem_kernel.dylib 0x3943d440 select$DARWIN_EXTSN + 20
1 CoreFoundation 0x2e6b6680 __CFSocketManager + 480
2 libsystem_pthread.dylib 0x394a5c1a _pthread_body + 138
3 libsystem_pthread.dylib 0x394a5b8a _pthread_start + 98
4 libsystem_pthread.dylib 0x394a3c8c thread_start + 4
Thread 5:
0 libsystem_kernel.dylib 0x3943d440 select$DARWIN_EXTSN + 20
1 ExternalAccessory 0x2eff4352 -[EAInputStream _readInputFromAccThread] + 342
2 Foundation 0x2f0cbc82 __NSThread__main__ + 1058
3 libsystem_pthread.dylib 0x394a5c1a _pthread_body + 138
4 libsystem_pthread.dylib 0x394a5b8a _pthread_start + 98
5 libsystem_pthread.dylib 0x394a3c8c thread_start + 4
Thread 6:
0 libsystem_kernel.dylib 0x3942aa8c mach_msg_trap + 20
1 libsystem_kernel.dylib 0x3942a888 mach_msg + 44
2 CoreFoundation 0x2e6b27be __CFRunLoopServiceMachPort + 150
3 CoreFoundation 0x2e6b0ee4 __CFRunLoopRun + 780
4 CoreFoundation 0x2e61bc22 CFRunLoopRunSpecific + 518
5 CoreFoundation 0x2e65f736 CFRunLoopRun + 94
6 CoreMotion 0x2ecd2230 ___lldb_unnamed_function1404$$CoreMotion + 724
7 libsystem_pthread.dylib 0x394a5c1a _pthread_body + 138
8 libsystem_pthread.dylib 0x394a5b8a _pthread_start + 98
9 libsystem_pthread.dylib 0x394a3c8c thread_start + 4
Thread 7:
0 libsystem_kernel.dylib 0x3943dc7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x394a3dc6 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x394a3c80 start_wqthread + 4
Thread 8:
0 libsystem_kernel.dylib 0x3943dc7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x394a3dc6 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x394a3c80 start_wqthread + 4
Thread 9:
0 libsystem_kernel.dylib 0x3943dc7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x394a3dc6 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x394a3c80 start_wqthread + 4
Thread 10:
0 libsystem_kernel.dylib 0x3943dc7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x394a3dc6 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x394a3c80 start_wqthread + 4
Thread 0 crashed with ARM Thread State (32-bit):
r0: 0x0281f840 r1: 0x31441b29 r2: 0x39647f78 r3: 0x000037f7
r4: 0x559b030e r5: 0x39632010 r6: 0x0281f840 r7: 0x27dde5a8
r8: 0x0281f844 r9: 0x1e2d1f1c r10: 0x16895960 r11: 0x00000000
ip: 0x3961f740 sp: 0x27dde568 lr: 0x2e618655 pc: 0x38e79b26
cpsr: 0x40000030

Is this crash in libdispatch caused by Reachability?

Can anyone tell me if this crashing stack appears to be caused by Reachability? I am running apple's latest implementation of Reachability, downloadable at https://developer.apple.com/library/ios/samplecode/reachability/Introduction/Intro.html
I have an app where ARC is not enabled by default (it is a legacy app) but I enable it on a per-file basis. I have enabled -fobjc-arc for Reachability.m
When I look at these threads, my code is nowhere to be found. I see some activity happening because of a WebHTMLView (probably the ad network view code currently on screen; it's not mine).
On Thread 10, I see a SCNetworkReachabilityDeallocate, then a dispatch_semaphore_wait_slow, and the crash happens on Thread 14 in libdispatch.
Do you think this crash is being caused by that Reachability code, and have I erred in using -fobjc-arc with Reachability.m?
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Subtype: KERN_INVALID_ADDRESS at 0x2000000c
Triggered by Thread: 14
Thread 0:
0 libsystem_kernel.dylib 0x39cafa84 mach_msg_trap + 20
1 libsystem_kernel.dylib 0x39caf87c mach_msg + 36
2 CoreFoundation 0x2f3e255c __CFRunLoopServiceMachPort + 152
3 CoreFoundation 0x2f3e0cc2 __CFRunLoopRun + 858
4 CoreFoundation 0x2f34b53c CFRunLoopRunSpecific + 520
5 CoreFoundation 0x2f34b31e CFRunLoopRunInMode + 102
6 GraphicsServices 0x340822e6 GSEventRunModal + 134
7 UIKit 0x31c021e0 UIApplicationMain + 1132
8 MyApp 0x00053ad4 main (main.m:33)
9 libdyld.dylib 0x39c0bab4 start + 0
Thread 1:
0 libsystem_kernel.dylib 0x39caf838 kevent64 + 24
1 libdispatch.dylib 0x39bfe0d0 _dispatch_mgr_invoke + 228
2 libdispatch.dylib 0x39bf863e _dispatch_mgr_thread + 34
Thread 2 name: com.apple.NSURLConnectionLoader
Thread 2:
0 libsystem_kernel.dylib 0x39cb0910 close + 8
1 CoreFoundation 0x2f370ef6 CFSocketInvalidate + 434
2 CFNetwork 0x2f0122a2 Schedulables::_SchedulablesInvalidateApplierFunction(void const*, void*) + 14
3 CoreFoundation 0x2f34af6e CFArrayApplyFunction + 34
4 CFNetwork 0x2f011a94 SocketStream::close(void const*) + 280
5 CFNetwork 0x2f01194e CoreStreamBase::_streamInterface_Close() + 46
6 CFNetwork 0x2f030286 HTTPReadFilter::_streamImpl_Close() + 66
7 CFNetwork 0x2f01194e CoreStreamBase::_streamInterface_Close() + 46
8 CFNetwork 0x2f0301c6 NetConnection::shutdownConnectionStreams() + 98
9 CFNetwork 0x2f0309c8 NetConnection::closeStreamsIfPossibleOrSignalThatThatNeedsToBeDonePrettyPlease() + 56
10 CFNetwork 0x2f030d12 HTTPConnectionCacheEntry::removeUnauthConnection(NetConnection*) + 182
11 CoreFoundation 0x2f34af6e CFArrayApplyFunction + 34
12 CFNetwork 0x2f075678 HTTPConnectionCacheEntry::purgeIdleConnections(double, double) + 256
13 CFNetwork 0x2f030ad4 HTTPConnectionCache::performIdleSweep() + 156
14 CFNetwork 0x2f073b42 HTTPConnectionCache::timeoutIdleCellConnections() + 18
15 CFNetwork 0x2f0b3394 ___ZNK17CoreSchedulingSet13_performAsyncEPKcU13block_pointerFvvE_block_invoke + 16
16 CoreFoundation 0x2f34af6e CFArrayApplyFunction + 34
17 CFNetwork 0x2f019f10 RunloopBlockContext::perform() + 160
18 CFNetwork 0x2f019de2 MultiplexerSource::perform() + 218
19 CFNetwork 0x2f019c70 MultiplexerSource::_perform(void*) + 44
20 CoreFoundation 0x2f3e2f24 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 12
21 CoreFoundation 0x2f3e23ea __CFRunLoopDoSources0 + 202
22 CoreFoundation 0x2f3e0bda __CFRunLoopRun + 626
23 CoreFoundation 0x2f34b53c CFRunLoopRunSpecific + 520
24 CoreFoundation 0x2f34b31e CFRunLoopRunInMode + 102
25 Foundation 0x2fd8664c +[NSURLConnection(Loader) _resourceLoadLoop:] + 316
26 Foundation 0x2fdfbdc2 __NSThread__main__ + 1058
27 libsystem_pthread.dylib 0x39d28c5a _pthread_body + 138
28 libsystem_pthread.dylib 0x39d28bca _pthread_start + 98
29 libsystem_pthread.dylib 0x39d26ccc thread_start + 4
Thread 3 name: WebThread
Thread 3:
0 CoreGraphics 0x2f49163c CGRectIsEmpty + 0
1 WebCore 0x37291700 -[WAKView setNeedsDisplayInRect:] + 76
2 WebKit 0x37cad22a -[WebHTMLView setNeedsDisplayInRect:] + 214
3 WebCore 0x372915cc WebCore::ScrollView::platformRepaintContentRectangle(WebCore::IntRect const&, bool) + 148
4 WebCore 0x37291412 WebCore::ScrollView::repaintContentRectangle(WebCore::IntRect const&, bool) + 98
5 WebCore 0x37291272 WebCore::FrameView::doDeferredRepaints() + 90
6 WebCore 0x372dc96c WebCore::FrameView::layout(bool) + 1748
7 WebCore 0x3721fb94 WebCore::ThreadTimers::sharedTimerFiredInternal() + 132
8 WebCore 0x3721fae6 WebCore::timerFired(__CFRunLoopTimer*, void*) + 22
9 CoreFoundation 0x2f3e2e84 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ + 12
10 CoreFoundation 0x2f3e2a9e __CFRunLoopDoTimer + 790
11 CoreFoundation 0x2f3e0e26 __CFRunLoopRun + 1214
12 CoreFoundation 0x2f34b53c CFRunLoopRunSpecific + 520
13 CoreFoundation 0x2f34b31e CFRunLoopRunInMode + 102
14 WebCore 0x372ae7d8 RunWebThread(void*) + 416
15 libsystem_pthread.dylib 0x39d28c5a _pthread_body + 138
16 libsystem_pthread.dylib 0x39d28bca _pthread_start + 98
17 libsystem_pthread.dylib 0x39d26ccc thread_start + 4
Thread 4:
0 libsystem_kernel.dylib 0x39cafa84 mach_msg_trap + 20
1 libsystem_kernel.dylib 0x39caf87c mach_msg + 36
2 CoreFoundation 0x2f3e255c __CFRunLoopServiceMachPort + 152
3 CoreFoundation 0x2f3e0c7c __CFRunLoopRun + 788
4 CoreFoundation 0x2f34b53c CFRunLoopRunSpecific + 520
5 CoreFoundation 0x2f34b31e CFRunLoopRunInMode + 102
6 libAVFAudio.dylib 0x2e3295ae GenericRunLoopThread::Entry(void*) + 126
7 libAVFAudio.dylib 0x2e31dbf4 CAPThread::Entry(CAPThread*) + 176
8 libsystem_pthread.dylib 0x39d28c5a _pthread_body + 138
9 libsystem_pthread.dylib 0x39d28bca _pthread_start + 98
10 libsystem_pthread.dylib 0x39d26ccc thread_start + 4
Thread 5 name: JavaScriptCore::BlockFree
Thread 5:
0 libsystem_kernel.dylib 0x39cc1f38 __psynch_cvwait + 24
1 libsystem_pthread.dylib 0x39d28262 _pthread_cond_wait + 538
2 libsystem_pthread.dylib 0x39d2903c pthread_cond_wait + 36
3 JavaScriptCore 0x3036f408 JSC::BlockAllocator::blockFreeingThreadMain() + 204
4 JavaScriptCore 0x3036ca70 WTF::wtfThreadEntryPoint(void*) + 12
5 libsystem_pthread.dylib 0x39d28c5a _pthread_body + 138
6 libsystem_pthread.dylib 0x39d28bca _pthread_start + 98
7 libsystem_pthread.dylib 0x39d26ccc thread_start + 4
Thread 6 name: JavaScriptCore::Marking
Thread 6:
0 libsystem_kernel.dylib 0x39cc1f38 __psynch_cvwait + 24
1 libsystem_pthread.dylib 0x39d28262 _pthread_cond_wait + 538
2 libsystem_pthread.dylib 0x39d2903c pthread_cond_wait + 36
3 JavaScriptCore 0x3050daf2 JSC::GCThread::waitForNextPhase() + 74
4 JavaScriptCore 0x3050db4c JSC::GCThread::gcThreadMain() + 48
5 JavaScriptCore 0x3036ca70 WTF::wtfThreadEntryPoint(void*) + 12
6 libsystem_pthread.dylib 0x39d28c5a _pthread_body + 138
7 libsystem_pthread.dylib 0x39d28bca _pthread_start + 98
8 libsystem_pthread.dylib 0x39d26ccc thread_start + 4
Thread 7 name: com.apple.CFSocket.private
Thread 7:
0 libsystem_kernel.dylib 0x39cc2440 select$DARWIN_EXTSN + 20
1 CoreFoundation 0x2f3e645e __CFSocketManager + 482
2 libsystem_pthread.dylib 0x39d28c5a _pthread_body + 138
3 libsystem_pthread.dylib 0x39d28bca _pthread_start + 98
4 libsystem_pthread.dylib 0x39d26ccc thread_start + 4
Thread 8 name: AFNetworking
Thread 8:
0 libsystem_kernel.dylib 0x39cafa84 mach_msg_trap + 20
1 libsystem_kernel.dylib 0x39caf87c mach_msg + 36
2 CoreFoundation 0x2f3e255c __CFRunLoopServiceMachPort + 152
3 CoreFoundation 0x2f3e0c7c __CFRunLoopRun + 788
4 CoreFoundation 0x2f34b53c CFRunLoopRunSpecific + 520
5 CoreFoundation 0x2f34b31e CFRunLoopRunInMode + 102
6 Foundation 0x2fd39822 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 250
7 Foundation 0x2fd8a664 -[NSRunLoop(NSRunLoop) run] + 76
8 MyApp 0x002c33d0 +[AFURLConnectionOperation networkRequestThreadEntryPoint:] (AFURLConnectionOperation.m:184)
9 Foundation 0x2fdfbdc2 __NSThread__main__ + 1058
10 libsystem_pthread.dylib 0x39d28c5a _pthread_body + 138
11 libsystem_pthread.dylib 0x39d28bca _pthread_start + 98
12 libsystem_pthread.dylib 0x39d26ccc thread_start + 4
Thread 9 name: WebCore: CFNetwork Loader
Thread 9:
0 libsystem_kernel.dylib 0x39cafa84 mach_msg_trap + 20
1 libsystem_kernel.dylib 0x39caf87c mach_msg + 36
2 CoreFoundation 0x2f3e255c __CFRunLoopServiceMachPort + 152
3 CoreFoundation 0x2f3e0c7c __CFRunLoopRun + 788
4 CoreFoundation 0x2f34b53c CFRunLoopRunSpecific + 520
5 CoreFoundation 0x2f34b31e CFRunLoopRunInMode + 102
6 WebCore 0x372f7872 WebCore::runLoaderThread(void*) + 250
7 JavaScriptCore 0x3036ca70 WTF::wtfThreadEntryPoint(void*) + 12
8 libsystem_pthread.dylib 0x39d28c5a _pthread_body + 138
9 libsystem_pthread.dylib 0x39d28bca _pthread_start + 98
10 libsystem_pthread.dylib 0x39d26ccc thread_start + 4
Thread 10:
0 libsystem_kernel.dylib 0x39cafad4 semaphore_wait_trap + 8
1 libdispatch.dylib 0x39bfcdec _dispatch_semaphore_wait_slow + 172
2 libxpc.dylib 0x39d370d6 xpc_connection_send_message_with_reply_sync + 150
3 SystemConfiguration 0x31b77362 _reach_server_target_remove + 90
4 SystemConfiguration 0x31b772d2 __SCNetworkReachabilityServer_targetRemove + 38
5 SystemConfiguration 0x31b5e318 __SCNetworkReachabilityDeallocate + 92
6 CoreFoundation 0x2f347efc CFRelease + 464
7 libdispatch.dylib 0x39bfc7e0 _dispatch_root_queue_drain + 220
8 libdispatch.dylib 0x39bfc9cc _dispatch_worker_thread2 + 52
9 libsystem_pthread.dylib 0x39d26dfc _pthread_wqthread + 296
10 libsystem_pthread.dylib 0x39d26cc0 start_wqthread + 4
Thread 11:
0 libsystem_kernel.dylib 0x39cc2c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x39d26e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x39d26cc0 start_wqthread + 4
Thread 12:
0 libsystem_kernel.dylib 0x39cc2c7c __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x39d26e06 _pthread_wqthread + 306
2 libsystem_pthread.dylib 0x39d26cc0 start_wqthread + 4
Thread 13:
0 libsystem_kernel.dylib 0x39cafa84 mach_msg_trap + 20
1 libsystem_kernel.dylib 0x39caf87c mach_msg + 36
2 CoreFoundation 0x2f3e255c __CFRunLoopServiceMachPort + 152
3 CoreFoundation 0x2f3e0c7c __CFRunLoopRun + 788
4 CoreFoundation 0x2f34b53c CFRunLoopRunSpecific + 520
5 CoreFoundation 0x2f38f1a6 CFRunLoopRun + 94
6 CoreMotion 0x2fa03394 ___lldb_unnamed_function1407$$CoreMotion + 724
7 libsystem_pthread.dylib 0x39d28c5a _pthread_body + 138
8 libsystem_pthread.dylib 0x39d28bca _pthread_start + 98
9 libsystem_pthread.dylib 0x39d26ccc thread_start + 4
Thread 14 Crashed:
0 libobjc.A.dylib 0x3970db66 objc_msgSend + 6
1 CoreFoundation 0x2f347f58 CFRelease + 556
2 libdispatch.dylib 0x39bf7100 _dispatch_call_block_and_release + 8
3 libdispatch.dylib 0x39bfbe72 _dispatch_queue_drain + 370
4 libdispatch.dylib 0x39bf8f96 _dispatch_queue_invoke + 38
5 libdispatch.dylib 0x39bfc74e _dispatch_root_queue_drain + 74
6 libdispatch.dylib 0x39bfc9cc _dispatch_worker_thread2 + 52
7 libsystem_pthread.dylib 0x39d26dfc _pthread_wqthread + 296
8 libsystem_pthread.dylib 0x39d26cc0 start_wqthread + 4
This crash could be caused by just about any piece of code, including your own.
The stack trace indicates that a block has previously retained a pointer that is now being released with CFRelease. If the pointer was not properly retained in the first place - or was in the process of being dealloc-ed when it was originally retained, you could see this stack trace.
If you are accessing the pointer on one thread, but releasing it another, then you may well have the kind of race condition that can cause this kind of crash.

Cocos2D 2 OSX EXC_BAD_ACCESS (SIGSEGV)

I'm updating a Game I have for the Mac and the update works fine while running through XCode.
I try to Distribute through Developer ID-signed Application so I can have a friend test it and when I run the app and also give them the app it crashes just after the Main Menu. Am I exporting it wrong? Why would it run fine through XCode and then I try to export it and it crashes every time?
Here is my error log:
Crashed Thread: 6 CVDisplayLink
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: KERN_INVALID_ADDRESS at 0x0000000121028021
VM Regions Near 0x121028021:
CG shared images 000000011f294000-000000011f29c000 [ 32K] r--/r-- SM=SHM
-->
CG shared images 00000001c0001000-00000001c0009000 [ 32K] rw-/rw- SM=SHM
Thread 0:: Dispatch queue: com.apple.main-thread
0 libsystem_kernel.dylib 0x00007fff91ef6686 mach_msg_trap + 10
1 libsystem_kernel.dylib 0x00007fff91ef5c42 mach_msg + 70
2 com.apple.CoreFoundation 0x00007fff8bf01803 __CFRunLoopServiceMachPort + 195
3 com.apple.CoreFoundation 0x00007fff8bf06ee6 __CFRunLoopRun + 1078
4 com.apple.CoreFoundation 0x00007fff8bf066b2 CFRunLoopRunSpecific + 290
5 com.apple.HIToolbox 0x00007fff943620a4 RunCurrentEventLoopInMode + 209
6 com.apple.HIToolbox 0x00007fff94361e42 ReceiveNextEventCommon + 356
7 com.apple.HIToolbox 0x00007fff94361cd3 BlockUntilNextEventMatchingListInMode + 62
8 com.apple.AppKit 0x00007fff961c8613 _DPSNextEvent + 685
9 com.apple.AppKit 0x00007fff961c7ed2 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 128
10 com.apple.AppKit 0x00007fff961bf283 -[NSApplication run] + 517
11 com.apple.AppKit 0x00007fff96163cb6 NSApplicationMain + 869
12 libdyld.dylib 0x00007fff916837e1 start + 1
Thread 1:
0 libsystem_kernel.dylib 0x00007fff91ef86d6 __workq_kernreturn + 10
1 libsystem_c.dylib 0x00007fff8ce15eec _pthread_workq_return + 25
2 libsystem_c.dylib 0x00007fff8ce15cb3 _pthread_wqthread + 412
3 libsystem_c.dylib 0x00007fff8ce00171 start_wqthread + 13
Thread 2:: Dispatch queue: com.apple.libdispatch-manager
0 libsystem_kernel.dylib 0x00007fff91ef8d16 kevent + 10
1 libdispatch.dylib 0x00007fff91fbfdea _dispatch_mgr_invoke + 883
2 libdispatch.dylib 0x00007fff91fbf9ee _dispatch_mgr_thread + 54
Thread 3:
0 libsystem_kernel.dylib 0x00007fff91ef86d6 __workq_kernreturn + 10
1 libsystem_c.dylib 0x00007fff8ce15eec _pthread_workq_return + 25
2 libsystem_c.dylib 0x00007fff8ce15cb3 _pthread_wqthread + 412
3 libsystem_c.dylib 0x00007fff8ce00171 start_wqthread + 13
Thread 4:
0 libsystem_kernel.dylib 0x00007fff91ef86d6 __workq_kernreturn + 10
1 libsystem_c.dylib 0x00007fff8ce15eec _pthread_workq_return + 25
2 libsystem_c.dylib 0x00007fff8ce15cb3 _pthread_wqthread + 412
3 libsystem_c.dylib 0x00007fff8ce00171 start_wqthread + 13
Thread 5:
0 libsystem_kernel.dylib 0x00007fff91ef86d6 __workq_kernreturn + 10
1 libsystem_c.dylib 0x00007fff8ce15eec _pthread_workq_return + 25
2 libsystem_c.dylib 0x00007fff8ce15cb3 _pthread_wqthread + 412
3 libsystem_c.dylib 0x00007fff8ce00171 start_wqthread + 13
Thread 6 Crashed:: CVDisplayLink
0 com.lasthaven.wordshufflemac 0x000000010bacc52a -[GameScene scrambleWord:] + 158 (GameScene.m:322)
1 com.lasthaven.wordshufflemac 0x000000010baced36 -[GameScene setupNewWord] + 373 (GameScene.m:878)
2 com.lasthaven.wordshufflemac 0x000000010bacb6c1 -[GameScene initializeGame] + 941 (GameScene.m:112)
3 com.lasthaven.wordshufflemac 0x000000010bacb2fc -[GameScene init] + 428 (GameScene.m:56)
4 com.lasthaven.wordshufflemac 0x000000010baf30c1 +[CCNode node] + 33
5 com.lasthaven.wordshufflemac 0x000000010bacb11b +[GameScene scene] + 62 (GameScene.m:32)
6 com.lasthaven.wordshufflemac 0x000000010bac9f90 -[MenuScene playGame:] + 363 (MenuScene.m:301)
7 com.lasthaven.wordshufflemac 0x000000010baee7e3 -[CCMenu ccMouseUp:] + 112
8 com.lasthaven.wordshufflemac 0x000000010bb177fb -[CCEventDispatcher mouseUp:] + 101
9 com.apple.Foundation 0x00007fff97fa5220 -[NSObject(NSThreadPerformAdditions) performSelector:onThread:withObject:waitUntilDone:modes:] + 212
10 com.apple.Foundation 0x00007fff97fdf8b9 -[NSObject(NSThreadPerformAdditions) performSelector:onThread:withObject:waitUntilDone:] + 122
11 com.lasthaven.wordshufflemac 0x000000010bb17f25 -[CCEventDispatcher dispatchEvent:] + 140
12 com.apple.Foundation 0x00007fff97fab677 __NSThreadPerformPerform + 225
13 com.apple.CoreFoundation 0x00007fff8bee4101 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
14 com.apple.CoreFoundation 0x00007fff8bee3a25 __CFRunLoopDoSources0 + 245
15 com.apple.CoreFoundation 0x00007fff8bf06dc5 __CFRunLoopRun + 789
16 com.apple.CoreFoundation 0x00007fff8bf066b2 CFRunLoopRunSpecific + 290
17 com.apple.Foundation 0x00007fff97fb389e -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 268
18 com.lasthaven.wordshufflemac 0x000000010bb16888 -[CCDirectorDisplayLink getFrameForTime:] + 162
19 com.apple.CoreVideo 0x00007fff8c0c603d CVDisplayLink::performIO(CVTimeStamp*) + 203
20 com.apple.CoreVideo 0x00007fff8c0c52a4 CVDisplayLink::runIOThread() + 632
21 com.apple.CoreVideo 0x00007fff8c0c5013 startIOThread(void*) + 148
22 libsystem_c.dylib 0x00007fff8ce13742 _pthread_start + 327
23 libsystem_c.dylib 0x00007fff8ce00181 thread_start + 13
scratch that.
after staring at this line for hours:
0 com.lasthaven.wordshufflemac 0x000000010bacc52a -[GameScene scrambleWord:] + 158 (GameScene.m:322)
I realized that the code consisted of a for loop and I couldn't figure out what was wrong with it! So in the end I forgot to initialize the int i in beginning of the for loop.
for(int i = 0; i < [word length]; i++ {
}
So for something so simple that caused a crash outside of XCode but not within it drove me nuts!
Thanks for reading!