如何在我的代码中轻松找到触发此事件(即“程序接收信号:EXC_BAD_ACCESS”)的点?“程序接收信号:EXC_BAD_ACCESS” - 如何识别触发的线路?
当我得到这个,我看在控制台上,我没有看到任何额外的信息,如在这种情况下堆栈跟踪。我知道我可以在代码中加入断点,并尝试着手寻找,但是如果有一种方法可以更容易地找出没有很多断点的地方,那么将会很棒。
编辑1 - 重新键入回溯(重新这个答案),我看到这个,这似乎并没有突出我的代码中的点?
(gdb) backtrace
#0 0x00fd7a63 in objc_msgSend()
#1 0x06019780 in ??()
#2 0x0046cf16 in -[UISectionRowData refreshWithSection:tableView:tableViewRowData:]()
#3 0x0046a9e7 in -[UITableViewRowData numberOfRows]()
#4 0x003218c2 in -[UITableView noteNumberOfRowsChanged]()
#5 0x0032e2b8 in -[UITableView reloadData]()
#6 0x0032b470 in -[UITableView layoutSubviews]()
#7 0x01d33451 in -[CALayer layoutSublayers]()
#8 0x01d3317c in CALayerLayoutIfNeeded()
#9 0x01d2c37c in CA::Context::commit_transaction()
#10 0x01d2c0d0 in CA::Transaction::commit()
#11 0x01d5c7d5 in CA::Transaction::observer_callback()
#12 0x00e56fbb in __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__()
#13 0x00dec0e7 in __CFRunLoopDoObservers()
#14 0x00db4bd7 in __CFRunLoopRun()
#15 0x00db4240 in CFRunLoopRunSpecific()
#16 0x00db4161 in CFRunLoopRunInMode()
#17 0x017aa268 in GSEventRunModal()
#18 0x017aa32d in GSEventRun()
#19 0x002c342e in UIApplicationMain()
很简单:NSZombies。棘手的是SIGABRTs。 :( – 2011-02-28 00:37:01