मुझे यह क्रैश रिपोर्ट मिली, लेकिन मुझे नहीं पता कि इसे कैसे डीबग करना है।
Fatal Exception NSInvalidArgumentException
Can't add self as subview
0 ... CoreFoundation __exceptionPreprocess + 130
1 libobjc.A.dylib objc_exception_throw + 38
2 CoreFoundation -[NSException initWithCoder:]
3 UIKit -[UIView(Internal) _addSubview:positioned:relativeTo:] + 110
4 UIKit -[UIView(Hierarchy) addSubview:] + 30
5 UIKit __53-[_UINavigationParallaxTransition animateTransition:]_block_invoke + 1196
6 UIKit +[UIView(Animation) performWithoutAnimation:] + 72
7 UIKit -[_UINavigationParallaxTransition animateTransition:] + 732
8 UIKit -[UINavigationController _startCustomTransition:] + 2616
9 UIKit -[UINavigationController _startDeferredTransitionIfNeeded:] + 418
10 UIKit -[UINavigationController __viewWillLayoutSubviews] + 44
11 UIKit -[UILayoutContainerView layoutSubviews] + 184
12 UIKit -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 346
13 QuartzCore -[CALayer layoutSublayers] + 142
14 QuartzCore CA::Layer::layout_if_needed(CA::Transaction*) + 350
15 QuartzCore CA::Layer::layout_and_display_if_needed(CA::Transaction*) + 16
16 QuartzCore CA::Context::commit_transaction(CA::Transaction*) + 228
17 QuartzCore CA::Transaction::commit() + 314
18 QuartzCore CA::Transaction::observer_callback(__CFRunLoopObserver*, unsigned long, void*) + 56
IOS वर्जन 7.0.3 है। किसी को भी इस अजीब दुर्घटना का अनुभव?
अपडेट करें:
मुझे नहीं पता कि मेरे कोड में यह क्रैश कहां हुआ है, इसलिए मैं यहां कोड पोस्ट नहीं कर सकता, क्षमा करें।
दूसरा अद्यतन
नीचे उत्तर देखें।
मैंने एक श्रेणी बनाई है जो इन कॉलों को स्वीकार करती है और उन्हें यह सुनिश्चित करके सुरक्षित बनाती है कि कोई अन्य धक्का नहीं लग रहा है जबकि एक प्रगति पर है। बस अपने प्रोजेक्ट में कोड कॉपी करें और विधि स्विज़लिंग के कारण आप जाना अच्छा होगा।