ios异常分析NSInternalInconsistencyException

时间:2017-03-09 07:57:12

标签: ios exception

我的应用程序崩溃时出现了像此一样的NSInternalInconsistencyException

 Exception reason:NSInternalInconsistencyException
        Exception name:Can't cancel on a touch that isn't already active!
        Exception stack:(
        0   CoreFoundation                      0x0000000191a4d1d0 <redacted> + 148
    1   libobjc.A.dylib                     0x000000019048455c objc_exception_throw + 56
    2   CoreFoundation                      0x0000000191a4d08c <redacted> + 0
    3   Foundation                          0x000000019250502c <redacted> + 112
    4   UIKit                               0x0000000197fd1960 <redacted> + 404
    5   UIKit                               0x0000000197fcf970 <redacted> + 1648
    6   libdispatch.dylib                   0x00000001908d61fc <redacted> + 24
    7   libdispatch.dylib                   0x00000001908d61bc <redacted> + 16
    8   libdispatch.dylib                   0x00000001908e43dc <redacted> + 928
    9   libdispatch.dylib                   0x00000001908d99a4 <redacted> + 652
    10  libdispatch.dylib                   0x00000001908e634c <redacted> + 572
    11  libdispatch.dylib                   0x00000001908e60ac <redacted> + 124
    12  libsystem_pthread.dylib             0x0000000190adf2a0 _pthread_wqthread + 1288
    13  libsystem_pthread.dylib             0x0000000190aded8c start_wqthread + 4
)

我如何分析日志?比如这些数字标记是什么意思,&#34; + 148&#34; &#34; + 56&#34; ......?如何检测已调用此异常的代码。

1 个答案:

答案 0 :(得分:0)

这是从应用程序的发布版本崩溃,还是在Xcode中有它?如果在Xcode中请提供导致崩溃的代码?

查看您的报告,

  

在尚未激活的触摸屏上无法取消!

似乎非常有说服力。我会查看您的代码,以查找与HiddenField对象或UITouch交互的任何位置。我的猜测是,你手动打电话取消你不应该进行的交互的某个地方,并且存在一种竞争条件,在系统已经取消触摸之后有时会发生这种情况(反之亦然)。