iOS VoiceOver崩溃(发送到解除分配的实例的消息) [英] iOS VoiceOver crash (message sent to deallocated instance)

查看:204
本文介绍了iOS VoiceOver崩溃(发送到解除分配的实例的消息)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在启用VoiceOver的情况下运行我的应用时,我遇到了一个奇怪的崩溃。该应用程序有一个侧边栏界面(如Facebook)。当点击侧栏 UITableView 中的 UITableViewCell 之一时,我换出视图控制器(创建一个新的根据哪个单元格被轻敲并取消分配旧单元格。

I am getting a weird crash when running my app with VoiceOver enabled. The app has a sidebar interface (like Facebook). When tapping on one of the UITableViewCells in the sidebar UITableView, I swap out the view controller (create a new one based on which cell was tapped and deallocate the old one).

启用VoiceOver时,当我点击单元格时,我有时会崩溃。这种崩溃不会每次都发生(大约每两次或三次尝试)并且这不是导致崩溃的唯一因素(但在我的测试中它是触发它的主要因素)。

While VoiceOver is enabled, I sometimes get a crash when I tap the cell. This crash does not occur every time (it is about once every two or three tries) and this is not the only thing that causes the crash (but in my testing it is the main thing that triggers it).

请记住,此次崩溃仅发生 ,然后启用VoiceOver。

Keep in mind this crash only happens then VoiceOver is enabled.

我通常会在发生崩溃时控制台。

I usually get this line in the console when the crash occurs.


*** - [UITableTextAccessibilityElement setAccessibilityLabel:]:发送到解除分配的实例0x1fdaec10的消息

*** -[UITableTextAccessibilityElement setAccessibilityLabel:]: message sent to deallocated instance 0x1fdaec10

但我也见过


*终止app由于未捕获的异常'NSRangeException',原因:'* - [__ NSArrayM objectAtIndex:]:索引6超出边界[0 .. 4]'
注意我看到 NSRangeException 启用了异常断点,它不会指向我的代码中发生错误的位置。

* Terminating app due to uncaught exception 'NSRangeException', reason: '* -[__NSArrayM objectAtIndex:]: index 6 beyond bounds [0 .. 4]' Note then I see the NSRangeException with exception breakpoints enabled, it does not point me to a place in my code where the error occured.

所以我启用了NSZombies并在仪器中运行应用程序。我的任何代码都没有触及过对象引用。

So I enabled NSZombies and ran the app in Instruments. The object references was never touched by any of my code.

我也是尝试在调试器外部运行时获取崩溃日志,但不幸的是Xcode无法对它们进行符号化。

I also tried getting a crash log when running outside of the debugger, but unfortunatly Xcode was not able to symbolicate them.


Last Exception Backtrace:

Last Exception Backtrace:

0 CoreFoundation 0x2e3c3f46 __exceptionPreprocess + 126

0 CoreFoundation 0x2e3c3f46 __exceptionPreprocess + 126

1 libobjc.A.dylib 0x387536aa objc_exception_throw + 34

1 libobjc.A.dylib 0x387536aa objc_exception_throw + 34

2 CoreFoundation 0x2e2fa52e - [__ NSArrayM objectAtIndex:] + 226

2 CoreFoundation 0x2e2fa52e -[__NSArrayM objectAtIndex:] + 226

3 APP-NAME 0x000e3726 0x46000 + 644902

3 APP-NAME 0x000e3726 0x46000 + 644902

4 UIKit 0x0250462e 0x24c6000 + 255534

4 UIKit 0x0250462e 0x24c6000 + 255534

5 UIAccessibility 0x35c029f8 - [NSObject(AXPrivCategory)accessibilityElementCount] + 16

5 UIAccessibility 0x35c029f8 -[NSObject(AXPrivCategory) accessibilityElementCount] + 16

6 UIAccessibility 0x35bfe66a _appendChildrenToArraySt artingAtIndexWithChildren + 318

6 UIAccessibility 0x35bfe66a _appendChildrenToArrayStartingAtIndexWithChildren + 318

7 UIAccessibility 0x35bfe51e _appendChildrenToArrayStartingAtIndex + 86

7 UIAccessibility 0x35bfe51e _appendChildrenToArrayStartingAtIndex + 86

8 UIAccessibility 0x35bfe460 _addAXElementsToArrayFromObject + 1580

8 UIAccessibility 0x35bfe460 _addAXElementsToArrayFromObject + 1580

9 UIAccessibility 0x35bfddfc _appendVendedAXElementsFromUIElements + 156

9 UIAccessibility 0x35bfddfc _appendVendedAXElementsFromUIElements + 156

10 UIAccessibility 0x35bfdbfe _createAXUIElementsFromUIElements + 126

10 UIAccessibility 0x35bfdbfe _createAXUIElementsFromUIElements + 126

11 UIAccessibility 0x35bfc218 _copyParameterizedAttributeValueCallback
+ 152

11 UIAccessibility 0x35bfc218 _copyParameterizedAttributeValueCallback + 152

12 AXRuntime 0x3152395c _AXXMIGCopyParameterizedAttributeValue + 168

12 AXRuntime 0x3152395c _AXXMIGCopyParameterizedAttributeValue + 168

13 AXRuntime 0x3152084e _XCopyParameterizedAttributeValue + 438

13 AXRuntime 0x3152084e _XCopyParameterizedAttributeValue + 438

14 AXRuntime 0x31528158 mshMIGPerform + 184

14 AXRuntime 0x31528158 mshMIGPerform + 184

15 CoreFoundation 0x2e38e9da CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION + 30

15 CoreFoundation 0x2e38e9da CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION + 30

16 CoreFoundation 0x2e38e976 __CFRunLoopDoSource1 + 342

16 CoreFoundation 0x2e38e976 __CFRunLoopDoSource1 + 342

17 CoreFoundation 0x2e38d14a __CFRunLoopRun + 1394

17 CoreFoundation 0x2e38d14a __CFRunLoopRun + 1394

18 CoreFoundation 0x2e2f7c22 CFRunLoopRunSpecific + 518

18 CoreFoundation 0x2e2f7c22 CFRunLoopRunSpecific + 518

19 CoreFoundation 0x2e2f7a06 CFRunLoopRunInMode + 102

19 CoreFoundation 0x2e2f7a06 CFRunLoopRunInMode + 102

20 GraphicsServices 0x32fd627e GSEventRunModal + 134

20 GraphicsServices 0x32fd627e GSEventRunModal + 134

21 UIKit 0x30b9b044 UIApplicationMain + 1132

21 UIKit 0x30b9b044 UIApplicationMain + 1132

22 APP-NAME 0x000509e2 0x46000 + 43490

22 APP-NAME 0x000509e2 0x46000 + 43490

23 libdyld.dylib 0x38c5bab2 tlv_initializer + 2

23 libdyld.dylib 0x38c5bab2 tlv_initializer + 2

崩溃发生在iOS 6和7上。我也尝试从整个应用程序中删除每个辅助功能调用,但应用程序仍在崩溃。

The crash occurs on iOS 6 and 7. I also tried removing every accessibility call from the entire app, but the app was still crashing.

我一直试图弄清楚这一周,并且不觉得我越来越近了。关于从哪里开始的任何想法?

I have been trying to figure this out all week and do not feel like I am getting any closer. Any ideas on where to proceed from here?

推荐答案

我们能够通过在iOS 6而不是7上调试来找到问题。

We were able to find the problem by debugging on iOS 6 instead of 7.

在iOS 6中,


AX错误:找不到我的模拟父母,我很可能是陈旧的。

AX ERROR: Could not find my mock parent, most likely I am stale.

出现在控制台中。结合提到的 UITableViewCell 错误,我们挖掘了侧边栏中的所有表格代码。

was showing up in the console. That combined with the UITableViewCell error mentioned about, we dug through all of the table code in the sidebar.

我们发现我们使用可重复使用的 UITableViewCells 作为标题视图,这导致了我们看到的僵尸问题。

We found that we were using reusable UITableViewCells as header views, and that was causing the zombie issue that we were seeing.

所以底线,不要使用 UITableViewCells 作为 UITableView 页眉/页脚视图。

So bottom line, don't use UITableViewCells as UITableView header/footer view.

这篇关于iOS VoiceOver崩溃(发送到解除分配的实例的消息)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆