关闭并再次运行时iphone应用程序崩溃,原因是什么?

时间:2011-07-25 04:59:36

标签: iphone objective-c xcode

我的应用程序第一次运行正常,但是当我终止它(关闭后台实例)并再次运行时,应用程序已经崩溃并且这引发了这个日志:

Elapsed total CPU time (seconds): 19.560 (user 19.000, system 0.560), 98% CPU 
Elapsed application CPU time (seconds): 19.000, 95% CPU

Thread 0:
0   libobjc.A.dylib                 0x33479482 0x33476000 + 13442
1   JdP                             0x0001a478 0x1000 + 103544
2   libobjc.A.dylib                 0x33479888 0x33476000 + 14472
3   libobjc.A.dylib                 0x3347f526 0x33476000 + 38182
4   libobjc.A.dylib                 0x3347bf32 0x33476000 + 24370
5   libobjc.A.dylib                 0x3347977a 0x33476000 + 14202
6   libobjc.A.dylib                 0x334794b0 0x33476000 + 13488
7   JdP                             0x0005c4c0 0x1000 + 373952
8   JdP                             0x0000406c 0x1000 + 12396
9   JdP                             0x00003e42 0x1000 + 11842
10  UIKit                           0x320a0270 0x32062000 + 254576
11  UIKit                           0x320acd04 0x32062000 + 306436
12  UIKit                           0x320acb74 0x32062000 + 306036
13  UIKit                           0x320aca72 0x32062000 + 305778
14  UIKit                           0x320ac54a 0x32062000 + 304458
15  UIKit                           0x320ac358 0x32062000 + 303960
16  UIKit                           0x320ac29c 0x32062000 + 303772
17  UIKit                           0x320ac238 0x32062000 + 303672
18  UIKit                           0x320750c8 0x32062000 + 78024
19  CoreFoundation                  0x33a5ebb8 0x33a20000 + 256952
20  QuartzCore                      0x3410867e 0x340f9000 + 63102
21  QuartzCore                      0x34108436 0x340f9000 + 62518
22  QuartzCore                      0x34102566 0x340f9000 + 38246
23  QuartzCore                      0x3410237c 0x340f9000 + 37756
24  QuartzCore                      0x3410ce48 0x340f9000 + 81480
25  QuartzCore                      0x34109b6e 0x340f9000 + 68462
26  UIKit                           0x320ac038 0x32062000 + 303160
27  UIKit                           0x3209a310 0x32062000 + 230160
28  UIKit                           0x32066484 0x32062000 + 17540
29  UIKit                           0x32065ec2 0x32062000 + 16066
30  UIKit                           0x32065900 0x32062000 + 14592
31  GraphicsServices                0x33b0eefc 0x33b0a000 + 20220
32  CoreFoundation                  0x33a556f8 0x33a20000 + 218872
33  CoreFoundation                  0x33a556bc 0x33a20000 + 218812
34  CoreFoundation                  0x33a47f76 0x33a20000 + 163702
35  CoreFoundation                  0x33a47c80 0x33a20000 + 162944
36  CoreFoundation                  0x33a47b88 0x33a20000 + 162696
37  UIKit                           0x32099302 0x32062000 + 226050
38  UIKit                           0x32096e8c 0x32062000 + 216716
39  JdP                             0x00002cbc 0x1000 + 7356
40  JdP                             0x00002c70 0x1000 + 7280

Thread 1:
0   libSystem.B.dylib               0x33b89974 0x33b5c000 + 186740
1   libSystem.B.dylib               0x33c33704 0x33b5c000 + 882436
2   libSystem.B.dylib               0x33c33174 0x33b5c000 + 881012
3   libSystem.B.dylib               0x33c32b98 0x33b5c000 + 879512
4   libSystem.B.dylib               0x33bd724a 0x33b5c000 + 504394
5   libSystem.B.dylib               0x33bcf970 0x33b5c000 + 473456

Thread 2:
0   libSystem.B.dylib               0x33b5d268 0x33b5c000 + 4712
1   libSystem.B.dylib               0x33b5f354 0x33b5c000 + 13140
2   CoreFoundation                  0x33a48648 0x33a20000 + 165448
3   CoreFoundation                  0x33a47ed2 0x33a20000 + 163538
4   CoreFoundation                  0x33a47c80 0x33a20000 + 162944
5   CoreFoundation                  0x33a47b88 0x33a20000 + 162696
6   WebCore                         0x304df124 0x30428000 + 749860
7   libSystem.B.dylib               0x33bd6886 0x33b5c000 + 501894
8   libSystem.B.dylib               0x33bcba88 0x33b5c000 + 457352

Unknown thread crashed with unknown flavor: 5, state_count: 1

我真的不知道调试此应用的原因和方法,请帮助我!

2 个答案:

答案 0 :(得分:0)

我认为您的应用需要很多时间才能退出。

请检查您的后台主题。

这是推荐链接: Crash Reports for iOS

答案 1 :(得分:0)

检查是否正在使用任何同步方法,例如在退出/启动/多任务处理时检查网络可用性等,这会阻止主循环。因此,由于超时,操作系统正在退出您的应用