【问题标题】:iOS App in AppStore crashes after update to iOS 8.0.2 but still running on devices and simulator更新到 iOS 8.0.2 后,AppStore 中的 iOS 应用程序崩溃,但仍在设备和模拟器上运行
【发布时间】:2014-12-03 10:37:00
【问题描述】:

很久以前在 AppStore 中发布的应用程序就有问题。更新到 iOS 8.0.2 后确实出现了该问题,并且通过选择 UITableViewCell 并推送另一个 UITableView 似乎仅在具有 iOS 8.0.2 的设备上崩溃。当在模拟器(带有 iOS 8.0 的 iPhone 6)或设备(带有 iOS 8.0.2 的 iPhone 5s)上运行应用程序时,我没有崩溃!

开发:Xcode 版本 6.0.1 (6A317) 和模拟器版本 8.0 (550.1)

我从 iphone 5s 获得的这个崩溃日志(myAppName 和 myCompanyName 是占位符):

Incident Identifier: 08332336-8EB8-46FE-A2EF-ABD2CE09881E
CrashReporter Key:   7ada6e35d37d8707ba1d6998b81491a622418c8e
Hardware Model:      iPhone6,2
Process:             myAppName [2629]
Path:                /private/var/mobile/Containers/Bundle/Application/9C0AFA6C-8C2C-4A44-9DAA-27ABF1326EA1/myAppName.app/myAppName
Identifier:          myCompanyName
Version:             3.0
Code Type:           ARM (Native)
Parent Process:      launchd [1]

Date/Time:           2014-10-08 17:40:14.116 +0200
Launch Time:         2014-10-08 17:40:12.799 +0200
OS Version:          iOS 8.0.2 (12A405)
Report Version:      105

Exception Type:  EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Triggered by Thread:  0

Last Exception Backtrace:
0   CoreFoundation                  0x24076e3f __exceptionPreprocess + 127
1   libobjc.A.dylib                 0x31752c8b objc_exception_throw + 38
2   CoreFoundation                  0x23f94ec3 -[__NSDictionaryM setObject:forKey:] + 850
3   myAppName                       0x00043e23 0x3000 + 265763
4   myAppName                       0x00043b3f 0x3000 + 265023
5   myAppName                       0x00044339 0x3000 + 267065
6   UIKit                           0x2761d1af __66-[UISectionRowData refreshWithSection:tableView:tableViewRowData:]_block_invoke + 514
7   UIKit                           0x275e2bb3 -[UISectionRowData refreshWithSection:tableView:tableViewRowData:] + 4018
8   UIKit                           0x275e1b41 -[UITableViewRowData rectForFooterInSection:heightCanBeGuessed:] + 328
9   UIKit                           0x275e1981 -[UITableViewRowData heightForTable] + 56
10  UIKit                           0x275e17b9 -[UITableView _updateContentSize] + 344
11  UIKit                           0x275e7503 -[UITableView didMoveToWindow] + 70
12  UIKit                           0x27511ff5 -[UIView(Internal) _didMoveFromWindow:toWindow:] + 1312
13  UIKit                           0x27530da3 -[UIScrollView _didMoveFromWindow:toWindow:] + 50
14  UIKit                           0x27511d65 -[UIView(Internal) _didMoveFromWindow:toWindow:] + 656
15  UIKit                           0x27511d65 -[UIView(Internal) _didMoveFromWindow:toWindow:] + 656
16  UIKit                           0x27511671 __45-[UIView(Hierarchy) _postMovedFromSuperview:]_block_invoke + 112
17  UIKit                           0x2751158d -[UIView(Hierarchy) _postMovedFromSuperview:] + 428
18  UIKit                           0x2751b9b3 -[UIView(Internal) _addSubview:positioned:relativeTo:] + 1434
19  UIKit                           0x2751b413 -[UIView(Hierarchy) addSubview:] + 30
20  UIKit                           0x275c74bf -[UINavigationTransitionView transition:fromView:toView:] + 478
21  UIKit                           0x275c72db -[UINavigationTransitionView transition:toView:] + 26
22  UIKit                           0x275beb67 -[UINavigationController _startTransition:fromViewController:toViewController:] + 2286
23  UIKit                           0x275bdff3 -[UINavigationController _startDeferredTransitionIfNeeded:] + 578
24  UIKit                           0x2759b1f7 -[UINavigationController pushViewController:transition:forceImmediate:] + 1506
25  UIKit                           0x27807ba9 __54-[UINavigationController pushViewController:animated:]_block_invoke + 356
26  UIKit                           0x2759ac03 -[UINavigationController pushViewController:animated:] + 494
27  myAppName                       0x00006ea1 0x3000 + 16033
28  UIKit                           0x2762b477 -[UITableView _selectRowAtIndexPath:animated:scrollPosition:notifyDelegate:] + 918
29  UIKit                           0x276dcd7f -[UITableView _userSelectRowAtPendingSelectionIndexPath:] + 194
30  UIKit                           0x2758ed0d _applyBlockToCFArrayCopiedToStack + 308
31  UIKit                           0x2750ac4b _afterCACommitHandler + 458
32  CoreFoundation                  0x2403d5cd __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 20
33  CoreFoundation                  0x2403ac8b __CFRunLoopDoObservers + 278
34  CoreFoundation                  0x2403b093 __CFRunLoopRun + 914
35  CoreFoundation                  0x23f89621 CFRunLoopRunSpecific + 476
36  CoreFoundation                  0x23f89433 CFRunLoopRunInMode + 106
37  GraphicsServices                0x2b2f80a9 GSEventRunModal + 136
38  UIKit                           0x27574359 UIApplicationMain + 1440
39  myAppName                       0x00004df9 0x3000 + 7673
40  myAppName                       0x00004d0c 0x3000 + 7436


Thread 0 name:  Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0   libsystem_kernel.dylib          0x31d98dfc __pthread_kill + 8
1   libsystem_pthread.dylib         0x31e16d33 pthread_kill + 59
2   libsystem_c.dylib               0x31d38905 abort + 73
3   libc++abi.dylib                 0x310779c5 abort_message + 85
4   libc++abi.dylib                 0x3109166d default_terminate_handler() + 265
5   libobjc.A.dylib                 0x31752f23 _objc_terminate() + 191
6   libc++abi.dylib                 0x3108ede1 std::__terminate(void (*)()) + 77
7   libc++abi.dylib                 0x3108e8ab __cxa_rethrow + 99
8   libobjc.A.dylib                 0x31752dcf objc_exception_rethrow + 39
9   CoreFoundation                  0x23f896b9 CFRunLoopRunSpecific + 629
10  CoreFoundation                  0x23f8942f CFRunLoopRunInMode + 103
11  GraphicsServices                0x2b2f80a5 GSEventRunModal + 133
12  UIKit                           0x27574355 UIApplicationMain + 1437
13  myCompany                       0x00004df5 0x3000 + 7669
14  myCompany                       0x00004d08 0x3000 + 7432

Thread 0 crashed with ARM Thread State (32-bit):
    r0: 0x00000000    r1: 0x00000000      r2: 0x00000000      r3: 0x00000003
    r4: 0x00000006    r5: 0x341bf9dc      r6: 0x341ab840      r7: 0x001803f8
    r8: 0x1764f6a0    r9: 0x00000000     r10: 0x341aa074     r11: 0x1764f6c4
    ip: 0x00000148    sp: 0x001803ec      lr: 0x31e16d37      pc: 0x31d98dfc
  cpsr: 0x00000010

我认为问题可能出在使用新 iOS 8.0.2 或类似版本更新的库上。

我迫切需要帮助来解决这个问题!

【问题讨论】:

  • 你能象征崩溃吗?第 3 行到第 5 行对于解决问题很重要。
  • 你的意思是那几行:3 code libc++abi.dylib 0x310779c5 abort_message + 85 4 libc++abi.dylib 0x3109166d default_terminate_handler() + 265 5 libobjc.A.dylib 0x31752f23 _objc ) + 191 code
  • 没有。在线程 0 中有一些以 "myAppName" 开头的行。这些是您的应用程序中导致崩溃的代码行。
  • 我已经说过,后面有一个AppName和hexcode
  • @AlexejW。您需要符号化您的崩溃报告,否则您无法确定崩溃发生在哪一行代码

标签: ios objective-c xcode crash-reports


【解决方案1】:

我不确定这是不是同样的问题,但我也看到一些来自 8.0.2 的崩溃,这与字体有关。

例如,我的 AppDelegate 中有此自定义:

    [[UILabel appearance] setFont:[UIFont fontWithName:@"HelveticaNeue-CondensedBold" size:14.0]];

导致这些崩溃的原因。

【讨论】:

  • 即使我在 8.0 和 8.0.2 中也遇到了一些崩溃问题。我们还按照您提到的那样进行字体自定义。8.0 和 8.0.2 中的字体有问题吗?
  • 似乎如此,目前唯一的解决方案是删除那些 iOS 版本的字体自定义。
猜你喜欢
  • 1970-01-01
  • 2021-04-16
  • 1970-01-01
  • 2018-07-13
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2011-09-24
  • 1970-01-01
相关资源
最近更新 更多