问题描述
当我更改设备方向时,我正在使用的应用程序正在异常终止(崩溃)。我不能重现它这么频繁(它不会发生总是当我旋转,让我们说,机会是一些在0.01%左右),但它是一个严重的问题。我附加了崩溃报告的重要部分。
异常类型:EXC_BAD_ACCESS(SIGSEGV)
异常代码:KERN_INVALID_ADDRESS在0x6563616e
崩溃的线程:0
线程0名称:分派队列:com.apple.main线程
线程0崩溃:
0 libobjc.A.dylib 0x3233a5b0 objc_msgSend + 16
1的UIKit 0x36297b82 - [UISectionRowData refreshWithSection:的tableView:tableViewRowData:] + 1546
2的UIKit 0x3628301e - 〔UITableViewRowData rectForFooterInSection:] + 310
3的UIKit 0x3628358c - [UITableViewRowData heightForTable] + 48
4 UIKit 0x36283400 - [UITableView(_UITableViewPrivate)_updateContentSize] + 324
5 UIKit 0x362cc8b4 - [UITableView _rectChangedWithNewSize:oldSize:] + 252
6 UIKit 0x362cc544 - [UITableView setFrame:] + 220
7 UIKit的0x362c59c4 - [UIView的(几何)_applyAutoresizingMaskWithOldSuperviewSize:] + 644
8 UIKit的0x362c572e - [UIView的(几何)_resizeWithOldSuperviewSize:] + 262
9 UIKit的0x3644eb2a - [UIScrollView的_resizeWithOldSuperviewSize:] + 38
10 CoreFoundation 0x35b63aec __NSArrayChunkIterate + 360
11 CoreFoundation 0x35b5ca74 __NSArrayEnumerate + 608
12 CoreFoundation 0x35abeb66 - [NSArray enumerateObjectsWithOptions:usingBlock:] + 58
13 UIKit 0x3627e09e - [UIView几何)resizeSubviewsWithOldSize:] + 114
14 UIKit 0x36263ba2 - [UIView(Geometry)setFrame:] + 414
15 UIKit 0x362c59c4 - [UIView(Geometry)_applyAutoresizingMaskWithOldSuperviewSize:] + 644
16 UIKit 0x362c572e - [UIView(Geometry)_resizeWithOldSuperviewSize:] + 262
17 CoreFoundation 0x35b63aec __NSArrayChunkIterate + 360
18 CoreFoundation 0x35b5ca74 __NSArrayEnumerate + 608
19 CoreFoundation 0x35abeb66 - [NSArray enumerateObjectsWithOptions:usingBlock:] + 58
20 UIKit 0x3627e09e - [UIView(Geometry)resizeSubviewsWithOldSize:] + 114
21 UIKit 0x36263ba2 - [UIView(Geometry)setFrame:] + 414
22 UIKit 0x362a6dc0 - [UIViewControllerWrapperView setFrame:] + 48
23分配的UIKit 0x362c59c4 - [UIView的(几何)_applyAutoresizingMaskWithOldSuperviewSize:] + 644
24的UIKit 0x362c572e - [UIView的(几何)_resizeWithOldSuperviewSize:] + 262
25的CoreFoundation 0x35b63aec __NSArrayChunkIterate + 360
26 CoreFoundation 0x35b5ca74 __NSArrayEnumerate + 608
27 CoreFoundation 0x35abeb66 - [NSArray enumerateObjectsWithOptions:usingBlock:] + 58
28 UIKit 0x3627e09e - [UIView(Geometry)resizeSubviewsWithOldSize:] + 114
29 UIKit 0x36263ba2 - [UIView (几何)setFrame:] + 414
30 UIKit 0x362c59c4 - [UIView(Geometry)_applyAutoresizingMaskWithOldSuperviewSize:] + 644
31 UIKit 0x362c572e - [UIView(Geometry)_resizeWithOldSuperviewSize:] + 262
32 CoreFoundation 0x35b63aec __NSArrayChunkIterate + 360
33的CoreFoundation 0x35b5ca74 __NSArrayEnumerate + 608
34的CoreFoundation 0x35abeb66 - [NSArray的enumerateObjectsWithOptions:usingBlock:] + 58
35的UIKit 0x3627e09e - [UIView的(几何)resizeSubviewsWithOldSize:] + 114
36 UIKit 0x362c64ae - [UIView(Geometry)setBounds:] + 430
37 UIKit 0x3634ff32 - [UILayoutContainerView setBounds:] + 58
38 UIKit 0x363edd88 - [UIViewController window:willAnimateRotationToInterfaceOrientation:duration:] + 460
39 UIKit 0x3630e2b0 - [UIWindow _setRotatableClient:toOrientation:updateStatusBar:duration:force:isRotating:] + 3616
40 UIKit 0x3630d482 - [UIWindow _setRotatableClient:toOrientation:updateStatusBar:duration:force:] + 42
41 UIKit 0x3630d40c - [UIWindow _setRotatableViewOrientation:duration:force:] + 64
42 UIKit 0x3644317c __57- [UIWindow _updateToInterfaceOrientation:duration:force:] _ block_invoke_0 + 100
43 UIKit 0x362cb676 - [UIWindow _updateToInterfaceOrientation :duration:force:] + 214
44 UIKit 0x362d4d20 - [UIWindow _updateInterfaceOrientationFromDeviceOrientation:] + 176
45 CoreFoundation 0x35ab9034 _CFXNotificationPost + 1424
46基础0x3721bd8c - [NSNotificationCenter postNotificationName:object:userInfo:] + 68
47 UIKit 0x36268c60 - [UIDevice setOrientation:animated:] + 292
48 UIKit 0x362633d6 - [UIApplication handleEvent:withNewEvent:] + 2954
49 UIKit 0x362626c8 - [UIApplication sendEvent:] + 68
50的UIKit 0x36262116 _UIApplicationHandleEvent + 6150
51 GraphicsServices 0x318885a0 _PurpleEventCallback + 588
52 GraphicsServices 0x318881ce PurpleEventCallback + 30
53的CoreFoundation 0x35b3d170 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 32
54的CoreFoundation 0x35b3d112 __CFRunLoopDoSource1 + 134
55的CoreFoundation 0x35b3bf94 __CFRunLoopRun + 1380
56的CoreFoundation 0x35aaeeb8 CFRunLoopRunSpecific + 352
57的CoreFoundation 0x35aaed44 CFRunLoopRunInMode + 100
58 GraphicsServices 0x318872e6 GSEventRunModal + 70
59的UIKit 0x362b62f4 UIApplicationMain + 1116
不涉及线程活动,也不定制ViewControllers。此外,我使用ARC。
我想知道原因的确切原因或自动旋转发生时会导致崩溃的可能性。
提前感谢...
I am getting abnormal termination (crash) with the App which I am working with when I am changing the device orientation. I am unable to reproduce it so often (it's not happening always when I am rotating, let's say the chance would be some where around 0.01%), but it's a serious problem. I am attaching an important part of a crash report.
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: KERN_INVALID_ADDRESS at 0x6563616e
Crashed Thread: 0
Thread 0 name: Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0 libobjc.A.dylib 0x3233a5b0 objc_msgSend + 16
1 UIKit 0x36297b82 -[UISectionRowData refreshWithSection:tableView:tableViewRowData:] + 1546
2 UIKit 0x3628301e -[UITableViewRowData rectForFooterInSection:] + 310
3 UIKit 0x3628358c -[UITableViewRowData heightForTable] + 48
4 UIKit 0x36283400 -[UITableView(_UITableViewPrivate) _updateContentSize] + 324
5 UIKit 0x362cc8b4 -[UITableView _rectChangedWithNewSize:oldSize:] + 252
6 UIKit 0x362cc544 -[UITableView setFrame:] + 220
7 UIKit 0x362c59c4 -[UIView(Geometry) _applyAutoresizingMaskWithOldSuperviewSize:] + 644
8 UIKit 0x362c572e -[UIView(Geometry) _resizeWithOldSuperviewSize:] + 262
9 UIKit 0x3644eb2a -[UIScrollView _resizeWithOldSuperviewSize:] + 38
10 CoreFoundation 0x35b63aec __NSArrayChunkIterate + 360
11 CoreFoundation 0x35b5ca74 __NSArrayEnumerate + 608
12 CoreFoundation 0x35abeb66 -[NSArray enumerateObjectsWithOptions:usingBlock:] + 58
13 UIKit 0x3627e09e -[UIView(Geometry) resizeSubviewsWithOldSize:] + 114
14 UIKit 0x36263ba2 -[UIView(Geometry) setFrame:] + 414
15 UIKit 0x362c59c4 -[UIView(Geometry) _applyAutoresizingMaskWithOldSuperviewSize:] + 644
16 UIKit 0x362c572e -[UIView(Geometry) _resizeWithOldSuperviewSize:] + 262
17 CoreFoundation 0x35b63aec __NSArrayChunkIterate + 360
18 CoreFoundation 0x35b5ca74 __NSArrayEnumerate + 608
19 CoreFoundation 0x35abeb66 -[NSArray enumerateObjectsWithOptions:usingBlock:] + 58
20 UIKit 0x3627e09e -[UIView(Geometry) resizeSubviewsWithOldSize:] + 114
21 UIKit 0x36263ba2 -[UIView(Geometry) setFrame:] + 414
22 UIKit 0x362a6dc0 -[UIViewControllerWrapperView setFrame:] + 48
23 UIKit 0x362c59c4 -[UIView(Geometry) _applyAutoresizingMaskWithOldSuperviewSize:] + 644
24 UIKit 0x362c572e -[UIView(Geometry) _resizeWithOldSuperviewSize:] + 262
25 CoreFoundation 0x35b63aec __NSArrayChunkIterate + 360
26 CoreFoundation 0x35b5ca74 __NSArrayEnumerate + 608
27 CoreFoundation 0x35abeb66 -[NSArray enumerateObjectsWithOptions:usingBlock:] + 58
28 UIKit 0x3627e09e -[UIView(Geometry) resizeSubviewsWithOldSize:] + 114
29 UIKit 0x36263ba2 -[UIView(Geometry) setFrame:] + 414
30 UIKit 0x362c59c4 -[UIView(Geometry) _applyAutoresizingMaskWithOldSuperviewSize:] + 644
31 UIKit 0x362c572e -[UIView(Geometry) _resizeWithOldSuperviewSize:] + 262
32 CoreFoundation 0x35b63aec __NSArrayChunkIterate + 360
33 CoreFoundation 0x35b5ca74 __NSArrayEnumerate + 608
34 CoreFoundation 0x35abeb66 -[NSArray enumerateObjectsWithOptions:usingBlock:] + 58
35 UIKit 0x3627e09e -[UIView(Geometry) resizeSubviewsWithOldSize:] + 114
36 UIKit 0x362c64ae -[UIView(Geometry) setBounds:] + 430
37 UIKit 0x3634ff32 -[UILayoutContainerView setBounds:] + 58
38 UIKit 0x363edd88 -[UIViewController window:willAnimateRotationToInterfaceOrientation:duration:] + 460
39 UIKit 0x3630e2b0 -[UIWindow _setRotatableClient:toOrientation:updateStatusBar:duration:force:isRotating:] + 3616
40 UIKit 0x3630d482 -[UIWindow _setRotatableClient:toOrientation:updateStatusBar:duration:force:] + 42
41 UIKit 0x3630d40c -[UIWindow _setRotatableViewOrientation:duration:force:] + 64
42 UIKit 0x3644317c __57-[UIWindow _updateToInterfaceOrientation:duration:force:]_block_invoke_0 + 100
43 UIKit 0x362cb676 -[UIWindow _updateToInterfaceOrientation:duration:force:] + 214
44 UIKit 0x362d4d20 -[UIWindow _updateInterfaceOrientationFromDeviceOrientation:] + 176
45 CoreFoundation 0x35ab9034 _CFXNotificationPost + 1424
46 Foundation 0x3721bd8c -[NSNotificationCenter postNotificationName:object:userInfo:] + 68
47 UIKit 0x36268c60 -[UIDevice setOrientation:animated:] + 292
48 UIKit 0x362633d6 -[UIApplication handleEvent:withNewEvent:] + 2954
49 UIKit 0x362626c8 -[UIApplication sendEvent:] + 68
50 UIKit 0x36262116 _UIApplicationHandleEvent + 6150
51 GraphicsServices 0x318885a0 _PurpleEventCallback + 588
52 GraphicsServices 0x318881ce PurpleEventCallback + 30
53 CoreFoundation 0x35b3d170 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 32
54 CoreFoundation 0x35b3d112 __CFRunLoopDoSource1 + 134
55 CoreFoundation 0x35b3bf94 __CFRunLoopRun + 1380
56 CoreFoundation 0x35aaeeb8 CFRunLoopRunSpecific + 352
57 CoreFoundation 0x35aaed44 CFRunLoopRunInMode + 100
58 GraphicsServices 0x318872e6 GSEventRunModal + 70
59 UIKit 0x362b62f4 UIApplicationMain + 1116
Neither thread activities are involved nor ViewControllers are customized. Moreover, I am using ARC.
I would like to know either the exact cause of reason or the possibilities which would lead to a crash while autorotation is taking place.
Thanks in advance...
I think app sends a message to an deallocated object. Yes, sometimes it happens even if when you use ARC. To debug it you need to run your app with Instruments (Zombies) and try to reproduce the bug.
这篇关于iOS中的自动崩溃的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!