2

希望能有一些见解来隔离这一点,中等复杂度的 iPhone 应用程序中的一些半可重复的崩溃......

当在应用程序的特定屏幕上按下 UIButton 时,会发生有问题的崩溃(有时,但并非始终如此)。

(目前还不确定,尽管在内存较低的情况下问题可能会更多地表现出来。)

下面摘录了一个典型的崩溃日志。

在这一点上不涉及很多不必要的细节 - 基于下面的日志,这是几个典型的 - 任何人都会对发生的问题有任何见解,以及在哪里查看和/或如何进一步排除故障?

很感谢任何形式的帮助!

谢谢。

~~~

Incident Identifier: ...
CrashReporter Key:   ...
Process:         AppName [1532]         
Path:            /var/mobile/Applications/12345678-9ABC-DEF0-1234-56789ABCDEF0/AppName.app/AppName
Identifier:      AppName
Version:         ??? (???)
Code Type:       ARM (Native)
Parent Process:  launchd [1]

Date/Time:       2010-01-05 18:20:28.081 -0800
OS Version:      iPhone OS 3.0.1 (7A400)
Report Version:  104

Exception Type:  EXC_BAD_ACCESS (SIGBUS)
Exception Codes: KERN_PROTECTION_FAILURE at 0x00000000
Crashed Thread:  0

Thread 0 Crashed:
0   libobjc.A.dylib                 0x30011944 objc_msgSend + 24
1   UIKit                           0x3096e0d0 -[UIApplication sendAction:to:from:forEvent:] + 128
2   UIKit                           0x3096e038 -[UIApplication sendAction:toTarget:fromSender:forEvent:] + 32
3   UIKit                           0x3096e000 -[UIControl sendAction:to:forEvent:] + 44
4   UIKit                           0x3096dc58 -[UIControl(Internal) _sendActionsForEvents:withEvent:] + 528
5   UIKit                           0x309a660c -[UIControl touchesBegan:withEvent:] + 260
6   UIKit                           0x30935100 _UIGestureRecognizerUpdateObserver + 2136
7   CoreFoundation                  0x3020cd8a __CFRunLoopDoObservers + 466
8   CoreFoundation                  0x3025488c CFRunLoopRunSpecific + 1812
9   CoreFoundation                  0x30254164 CFRunLoopRunInMode + 44
10  GraphicsServices                0x3204529c GSEventRunModal + 188
11  UIKit                           0x308f0374 -[UIApplication _run] + 552
12  UIKit                           0x308eea8c UIApplicationMain + 960
13  AppName                         0x00002090 0x1000 + 4240
14  AppName                         0x0000202c 0x1000 + 4140

Thread 1:
0   libSystem.B.dylib               0x31d47158 mach_msg_trap + 20
1   libSystem.B.dylib               0x31d49ed8 mach_msg + 60
2   CoreFoundation                  0x3025454e CFRunLoopRunSpecific + 982
3   CoreFoundation                  0x30254164 CFRunLoopRunInMode + 44
4   WebCore                         0x3588dbc8 __ZL12RunWebThreadPv + 412
5   libSystem.B.dylib               0x31d705a0 _pthread_body + 20

Thread 0 crashed with ARM Thread State:
    r0: 0x0019e420    r1: 0x30128c94      r2: 0x00014fac      r3: 0x001ce9a0
    r4: 0x001a56e4    r5: 0x00000000      r6: 0x00000000      r7: 0x2ffff1e0
    r8: 0x00014fac    r9: 0x001a97c0     r10: 0x001ce9a0     r11: 0x00000001
    ip: 0x388ed9f0    sp: 0x2ffff1b8      lr: 0x3096e0d8      pc: 0x30011944
  cpsr: 0x200f0010

~~~

4

1 回答 1

2

EXC_BAD_ACCESS + objc_msgSend 几乎总是等于将消息发送到已释放对象。

运行静态分析器,它应该会有所帮助。还启用了 NSZombies。

然后调试并玩得开心!

于 2010-01-06T07:01:25.240 回答