gpt4 book ai didi

ios - 我无法理解这两个崩溃报告

转载 作者:可可西里 更新时间:2023-11-01 05:45:43 26 4
gpt4 key购买 nike

由于我收到了关于崩溃的评论,但应用程序从来没有为我崩溃过,所以我现在使用批评来寻找崩溃。

我收到一份报告指出我犯了一个错误。这很容易,因为给出了方法名称并且我可以查看我的代码可能会崩溃的地方。到目前为止,还不错。

但我也有以下两个让我困惑的地方。

对我来说,应用程序似乎在某个内部苹果库中崩溃了。(很可能是因为我给它喂了一些破东西...)

崩溃时我的代码没有调用,那么从哪里开始查找呢?

有人了解这些崩溃吗?知道我如何捕捉这些并可能获得更多崩溃信息吗?第一:

0 CoreFoundation 0x3585f88f __exceptionPreprocess + 162
1 libobjc.A.dylib 0x37c06259 objc_exception_throw + 32
2 CoreFoundation 0x35862a9b -[NSObject doesNotRecognizeSelector:] + 174
3 CoreFoundation 0x35861915 ___forwarding___ + 300
4 CoreFoundation 0x357bc650 _CF_forwarding_prep_0 + 48
5 UIKit 0x332f3efb -[UITableView(UITableViewInternal) _createPreparedCellForGlobalRow:withIndexPath:] + 546
6 UIKit 0x332f2f39 -[UITableView(_UITableViewPrivate) _updateVisibleCellsNow:] + 916
7 UIKit 0x332f2763 -[UITableView layoutSubviews] + 206
8 UIKit 0x33296f37 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 182
9 CoreFoundation 0x357be1fb -[NSObject performSelector:withObject:] + 42
10 QuartzCore 0x3268eaa5 -[CALayer layoutSublayers] + 216
11 QuartzCore 0x3268e6bd _ZN2CA5Layer16layout_if_neededEPNS_11TransactionE + 216
12 QuartzCore 0x32692843 _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 226
13 QuartzCore 0x3269257f _ZN2CA11Transaction6commitEv + 314
14 QuartzCore 0x326ba911 _ZN2CA11Transaction5flushEv + 44
15 QuartzCore 0x326ba8e3 +[CATransaction flush] + 34
16 UIKit 0x332a1fb1 _afterCACommitHandler + 52
17 CoreFoundation 0x35833b1b __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 18
18 CoreFoundation 0x35831d57 __CFRunLoopDoObservers + 258
19 CoreFoundation 0x358320b1 __CFRunLoopRun + 760
20 CoreFoundation 0x357b54a5 CFRunLoopRunSpecific + 300
21 CoreFoundation 0x357b536d CFRunLoopRunInMode + 104
22 GraphicsServices 0x37451439 GSEventRunModal + 136
23 UIKit 0x332c1cd5 UIApplicationMain + 1080
24 Wohnungssuche 0x000d5218 start + 40

没有。 2:

Thread: Unknown Name (Crashed)
0 libobjc.A.dylib 0x35beb5d0 objc_msgSend + 16 + 15
1 UIKit 0x39fb0541 -[UITableView(UITableViewInternal) _createPreparedCellForGlobalRow:withIndexPath:] + 409 + 408
2 UIKit 0x39f95361 -[UITableView(_UITableViewPrivate) _updateVisibleCellsNow:] + 1317 + 1316
3 UIKit 0x39fac7ff -[UITableView layoutSubviews] + 207 + 206
4 UIKit 0x39f68897 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 259 + 258
5 QuartzCore 0x34ab74eb -[CALayer layoutSublayers] + 215 + 214
6 QuartzCore 0x34ab708d _ZN2CA5Layer16layout_if_neededEPNS_11TransactionE + 461 + 460
7 QuartzCore 0x34ab7fb1 _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 17 + 16
8 QuartzCore 0x34ab799b _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 239 + 238
9 QuartzCore 0x34ab77ad _ZN2CA11Transaction6commitEv + 317 + 316
10 QuartzCore 0x34aee7df _ZN2CA7Display11DisplayLink8dispatchEyy + 255 + 254
11 QuartzCore 0x34aee6d9 _ZN2CA7Display16IOMFBDisplayLink8callbackEP21__IOMobileFramebufferyyyPv + 65 + 64
12 IOMobileFramebuffer 0x375f0fd7 IOMobileFramebufferVsyncNotifyFunc + 155 + 154
13 IOKit 0x3282a5ad IODispatchCalloutFromCFMessage + 193 + 192
14 CoreFoundation 0x3918288b __CFMachPortPerform + 119 + 118
15 CoreFoundation 0x3918d3e7 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 35 + 34
16 CoreFoundation 0x3918d38b __CFRunLoopDoSource1 + 139 + 138
17 CoreFoundation 0x3918c20f __CFRunLoopRun + 1383 + 1382
18 CoreFoundation 0x390ff23d CFRunLoopRunSpecific + 357 + 356
19 CoreFoundation 0x390ff0c9 CFRunLoopRunInMode + 105 + 104
20 GraphicsServices 0x3344933b GSEventRunModal + 75 + 74
21 UIKit 0x39fb9291 UIApplicationMain + 1121 + 1120

感谢您的帮助!

最佳答案

两种情况的崩溃点是一样的:

 UIKit 0x39fb0541 -[UITableView(UITableViewInternal) _createPreparedCellForGlobalRow:withIndexPath:] + 409 + 408

在第一种情况下, TableView 试图在未实现所述方法的实例上调用方法。第二次崩溃是由于试图发送垃圾消息导致的。

因此,最有可能的结论是,两次崩溃都是同一个问题的征兆;您有一个对象被过早释放或过度释放。

特别是,您的 TableView 的数据源在表重新加载之前或期间被释放。

我怀疑 UITableView 正在尝试调用数据源的方法来创建单元格。您可以通过在所述方法上设置断点并查看堆栈跟踪来确认这一点。如果我的赌注是正确的,您将在跟踪中看到 _createPreparedCellForGlobal... 方法。


在不知道您应用的详细信息的情况下,很难说。最有可能的是,这是在屏幕上加载数据和用户执行某些操作导致请求在 TableView 完成加载之前被取消的时间相关问题,导致您的数据源从表下释放(这之所以会发生,是因为 TableView 具有对您的对象的分配引用;非保留引用)。

要尝试重现,请关注:

• 网络连接缓慢或带宽可变(如果您的应用是客户端/服务器)

• 执行用户可能会导致操作取消的操作

• 在 View 之间快速导航,无需等待更新完成绘制

在您的评论中,您提到您正在试用“两部不同的 iPhone”。在其他设备类型和不同的网络配置上尝试。

关于ios - 我无法理解这两个崩溃报告,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14611722/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com