iOS应用程序在线程0中崩溃

时间:2012-10-31 15:51:15

标签: iphone ios xcode crash-reports

我们的一位用户遇到了问题,即应用启动后App会直接崩溃。现在我们只收到两个崩溃报告,但无法在我们的任何设备上重现崩溃。 Build是一个企业分发版本。

设备是iPhone 4,带有iOS 6。

任何想法都会非常感激。

Date/Time:       2012-10-30 17:41:11.762 +0100
OS Version:      iOS 6.0 (10A403)
Report Version:  104

Exception Type:  EXC_CRASH (SIGTRAP)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Crashed Thread:  0

Thread 0 name:  Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0   libsystem_c.dylib              0x38edad8e memmove$VARIANT$CortexA8 + 654
1   QuartzCore                     0x3401c81c CA::Render::Encoder::encode_bytes(void const*, unsigned long) + 24
2   QuartzCore                     0x3401d494 CA::Render::Layer::Ext::encode(CA::Render::Encoder*) const + 152
3   QuartzCore                     0x3401c706 CA::Render::encode_set_object(CA::Render::Encoder*, unsigned long, unsigned int, CA::Render::Object*, unsigned int) + 42
4   QuartzCore                     0x3401b3e2 CA::Context::commit_layer(CA::Layer*, unsigned int, unsigned int, void*) + 114
5   QuartzCore                     0x34011076 CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 310
6   QuartzCore                     0x3401101c CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 220
7   QuartzCore                     0x3401101c CA::Layer::commit_if_needed(CA::Transaction*, void (*)(CA::Layer*, unsigned int, unsigned int, void*), void*) + 220
8   QuartzCore                     0x3401052c CA::Context::commit_transaction(CA::Transaction*) + 1024
9   QuartzCore                     0x34010024 CA::Transaction::commit() + 312
10  QuartzCore                     0x3400fe84 CA::Transaction::observer_callback(__CFRunLoopObserver*, unsigned long, void*) + 56
11  CoreFoundation                 0x34e326ca __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 18
12  CoreFoundation                 0x34e309bc __CFRunLoopDoObservers + 272
13  CoreFoundation                 0x34e30d12 __CFRunLoopRun + 738
14  CoreFoundation                 0x34da3eb8 CFRunLoopRunSpecific + 352
15  CoreFoundation                 0x34da3d44 CFRunLoopRunInMode + 100
16  GraphicsServices               0x35b0c2e6 GSEventRunModal + 70
17  UIKit                          0x379e92fc UIApplicationMain + 1116
18  MyApp                           0x000ceb90 main (main.m:16)
19  MyApp                           0x000ceb2c start + 36

这是第二个:

Date/Time:       2012-10-29 15:54:48.926 +0100
OS Version:      iOS 6.0 (10A403)
Report Version:  104

Exception Type:  EXC_CRASH (SIGTRAP)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Crashed Thread:  0

Thread 0 name:  Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0   libsystem_kernel.dylib         0x33b1beb4 mach_msg_trap + 20
1   libsystem_kernel.dylib         0x33b1c048 mach_msg + 36
2   CoreFoundation                 0x34e32040 __CFRunLoopServiceMachPort + 124
3   CoreFoundation                 0x34e30d5a __CFRunLoopRun + 810
4   CoreFoundation                 0x34da3eb8 CFRunLoopRunSpecific + 352
5   CoreFoundation                 0x34da3d44 CFRunLoopRunInMode + 100
6   GraphicsServices               0x35b0c2e6 GSEventRunModal + 70
7   UIKit                          0x379e92fc UIApplicationMain + 1116
8   MyApp                           0x00024b90 main (main.m:16)
9   MyApp                           0x00024b2c start + 36

1 个答案:

答案 0 :(得分:1)

第一个我怀疑你在把它们放到屏幕上时会有动画(因为它在发布期间发生)。也许您正在应用程序委托中执行与UI相关的操作,或者从屏幕上尚未显示的视图控制器执行此操作。也就是说,核心动画调用可能是一个红色的鲱鱼(见下文)。

第二个不太可能是实际崩溃点。 iOS无法始终确定哪个线程实际崩溃,有时会怪错误的(并且大多数情况下,线程0将被错误地归咎于)。崩溃_trap函数的可能性很小。此时线程通常被挂起。我会研究其他线程,看看其中一个是否做了可疑的事情。如果你在其他地方找到它,那么这也可能是第一次崩溃的原因。