iOS异常处理 :Mach_msg_trap异常求解

iOS异常处理 :Mach_msg_trap异常

程序运行时,xcode中断,显示信息

libsystem_kernel.dylib`mach_msg_trap:

0x215d3894 <+0>:  mov    r12, sp
0x215d3898 <+4>:  push   {r4, r5, r6, r8}
0x215d389c <+8>:  ldm    r12, {r4, r5, r6}
0x215d38a0 <+12>: mvn    r12, #30
0x215d38a4 <+16>: svc    #0x80

-> 0x215d38a8 <+20>: pop {r4, r5, r6, r8}
0x215d38ac <+24>: bx lr

并不是崩溃 也没有报错信息

bt 则显示

thread #1: tid = 0x1062df, 0x215d38a8 libsystem_kernel.dylib`mach_msg_trap + 20, queue = ‘com.apple.main-thread’, stop reason = signal SIGPIPE
  • frame #0: 0x215d38a8 libsystem_kernel.dylibmach_msg_trap + 20
    frame #1: 0x215d36a8 libsystem_kernel.dylib
    mach_msg + 40
    frame #2: 0x2191b6ac CoreFoundation__CFRunLoopServiceMachPort + 136
    frame #3: 0x21919a32 CoreFoundation
    __CFRunLoopRun + 1050
    frame #4: 0x218681c8 CoreFoundationCFRunLoopRunSpecific + 516
    frame #5: 0x21867fbc CoreFoundation
    CFRunLoopRunInMode + 108
    frame #6: 0x22e84af8 GraphicsServicesGSEventRunModal + 160
    frame #7: 0x25fa0434 UIKit
    UIApplicationMain + 144
    frame #8: 0x002b37aa Niuppmain(argc=1, argv=0x0210db10) + 106 at main.m:17
    frame #9: 0x21514872 libdyld.dylib
    start + 2

如果不是调试模式-APP会异常闪退

你可能感兴趣的:(iOS异常处理)