iOS应用程序崩溃setcontentoffset任何提示?

时间:2015-01-10 19:59:50

标签: ios objective-c uitableview crash-reports

根据Flurry的说法,uiscrollview/uitableview setcontentoffset周围的应用程序崩溃频率很高。

以下是其中的细节,任何人都面临类似的事情?

    0   libobjc.A.dylib                     0x39b80f46 _objc_msgSend + 5
    1   UIKit                               0x2f915795 -[UIScrollView setContentOffset:] + 632
    2   UIKit                               0x2f9c02c5 -[UITableView setContentOffset:] + 412
    3   UIKit                               0x2fba3b5f -[UIScrollView _adjustContentOffsetIfNecessary] + 1466
    4   UIKit                               0x2f9c6671 -[UIScrollView _stopScrollingNotify:pin:tramplingDragFlags:] + 452
    5   UIKit                               0x2f9c64a7 -[UIScrollView _stopScrollingNotify:pin:] + 30
    6   UIKit                               0x2f9c6463 -[UIScrollView removeFromSuperview] + 30
    7   UIKit                               0x2f8f8f47 -[UIView dealloc] + 382
    8   CoreFoundation                      0x2c36526d _CFRelease + 600
    9   CoreFoundation                      0x2c37c3bd -[__NSArrayM dealloc] + 148
    10  libobjc.A.dylib                     0x39b8ed5f  + 166
    11  libobjc.A.dylib                     0x39b8f1a9  + 404
    12  CoreFoundation                      0x2c3703a9 __CFAutoreleasePoolPop + 16
    13  CoreFoundation                      0x2c4222ef  + 1518
    14  CoreFoundation                      0x2c370621 _CFRunLoopRunSpecific + 476
    15  CoreFoundation                      0x2c370433 _CFRunLoopRunInMode + 106
    16  GraphicsServices                    0x336d80a9 _GSEventRunModal + 136
    17  UIKit                               0x2f95a809 _UIApplicationMain + 1440
    18  aNews                               0x00053b1b __mh_execute_header + 23323
    19  libdyld.dylib                       0x3a0f4aaf  + 2

1 个答案:

答案 0 :(得分:0)

我认为这是因为你不在主线程上执行setContentOffset。或者也许某些其他方法在后台,然后当它执行时它不在主线程上。当与UI相关时,一切都应该在主线程上完成。在主线程上尝试一下,看看是否能解决问题。