Hello,
I discovered a serious error in my app and after some time of analysing I have no idea how to fix it.
The app I work on crashes periodically with an error message like:
This problem happens with other NIB files, too, usually table view cells I designed with the interface builder.
There are two way for me to load the cells:
1. For cells that are linked to one table view: I add an IBOutlet to the table view controller and link the cell via IB to this outlet. Then I call [[NSBundle mainBundle] loadNibNamed: ...]. Then I simply get the cell from the outlet.
2. For cells I use in different table views: I call [[NSBundle mainBundle] loadNibNamed: ...] directly and evaluate the returned array of NIBs. Usually I get the first one.
Both of these ways fail.
I have no idea, what causes the problem and how to fix it, especially since the app works perfectly at the beginning (with the mentioned NIB files loaded).
Any ideas?
Best regards!
I discovered a serious error in my app and after some time of analysing I have no idea how to fix it.
The app I work on crashes periodically with an error message like:
Code:
2011-01-18 20:02:11.156 MeetingProtocol[1583:307] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Could not load NIB in bundle: 'NSBundle </var/mobile/Applications/E28E05D6-683B-4900-9815-1EC761079E43/MeetingProtocol.app> (loaded)' with name 'MeetingProtocolParticipantCell''
*** Call stack at first throw:
(
0 CoreFoundation 0x3587a987 __exceptionPreprocess + 114
1 libobjc.A.dylib 0x34a8249d objc_exception_throw + 24
2 CoreFoundation 0x3587a7c9 +[NSException raise:format:arguments:] + 68
3 CoreFoundation 0x3587a803 +[NSException raise:format:] + 34
4 UIKit 0x3438e783 -[UINib instantiateWithOwner:options:] + 1110
5 UIKit 0x3438fb39 -[NSBundle(UINSBundleAdditions) loadNibNamed:owner:options:] + 92
6 MeetingProtocol 0x0001013b -[MeetingProtocolViewController tableView:cellForRowAtIndexPath:] + 1874
7 UIKit 0x3420ea21 -[UITableView(UITableViewInternal) _createPreparedCellForGlobalRow:withIndexPath:] + 516
8 UIKit 0x3420e7f3 -[UITableView(UITableViewInternal) _createPreparedCellForGlobalRow:] + 34
9 UIKit 0x3420cd2d -[UITableView(_UITableViewPrivate) _updateVisibleCellsNow:] + 936
10 UIKit 0x3420bedd -[UITableView layoutSubviews] + 140
11 UIKit 0x341b80cf -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 26
12 CoreFoundation 0x35818bbf -[NSObject(NSObject) performSelector:withObject:] + 22
13 QuartzCore 0x31075685 -[CALayer layoutSublayers] + 120
14 QuartzCore 0x3107543d CALayerLayoutIfNeeded + 184
15 QuartzCore 0x3106f56d _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 212
16 QuartzCore 0x3106f383 _ZN2CA11Transaction6commitEv + 190
17 QuartzCore 0x31092f9d _ZN2CA11Transaction17observer_callbackEP19__CFRunLoopObservermPv + 52
18 CoreFoundation 0x3580ac59 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 16
19 CoreFoundation 0x3580aacd __CFRunLoopDoObservers + 412
20 CoreFoundation 0x358020cb __CFRunLoopRun + 854
21 CoreFoundation 0x35801c87 CFRunLoopRunSpecific + 230
22 CoreFoundation 0x35801b8f CFRunLoopRunInMode + 58
23 GraphicsServices 0x320c84ab GSEventRunModal + 114
24 GraphicsServices 0x320c8557 GSEventRun + 62
25 UIKit 0x341dc329 -[UIApplication _run] + 412
26 UIKit 0x341d9e93 UIApplicationMain + 670
27 MeetingProtocol 0x00002887 main + 70
28 MeetingProtocol 0x0000283c start + 40
)
terminate called after throwing an instance of 'NSException'
Program received signal: SIGABRT.
Data Formatters unavailable (Error calling dlopen for: "/Developer/usr/lib/libXcodeDebuggerSupport.dylib": "dlopen(/Developer/usr/lib/libXcodeDebuggerSupport.dylib, 10): no suitable image found. Did find:
/Developer/usr/lib/libXcodeDebuggerSupport.dylib: open() failed with errno=24
/Developer/usr/lib/libXcodeDebuggerSupport.dylib: stat() failed with errno=554240")
kill
quit
The Debugger has exited with status 0.
This problem happens with other NIB files, too, usually table view cells I designed with the interface builder.
There are two way for me to load the cells:
1. For cells that are linked to one table view: I add an IBOutlet to the table view controller and link the cell via IB to this outlet. Then I call [[NSBundle mainBundle] loadNibNamed: ...]. Then I simply get the cell from the outlet.
2. For cells I use in different table views: I call [[NSBundle mainBundle] loadNibNamed: ...] directly and evaluate the returned array of NIBs. Usually I get the first one.
Both of these ways fail.
I have no idea, what causes the problem and how to fix it, especially since the app works perfectly at the beginning (with the mentioned NIB files loaded).
Any ideas?
Best regards!