2015-11-04 45 views
0

我試圖從下面的代碼/代碼段中找到崩潰。如何從以下代碼檢測崩潰?

Thread : Crashed: com.apple.main-thread 
0 libobjc.A.dylib    6771342288 objc_msgSend + 16 
1 Foundation      6488040888 vars_index_with_insert + 396 
2 Foundation      6488046624 -[NSISLinearExpression setCoefficient:forVariable:] + 372 
3 Foundation      6488038164 -[NSLayoutConstraint _lowerIntoExpression:reportingConstantIsRounded:] + 432 
4 Foundation      6488033112 -[NSLayoutConstraint _tryToChangeContainerGeometryWithUndoHandler:] + 136 
5 Foundation      6488032176 -[NSLayoutConstraint _setSymbolicConstant:constant:] + 420 
6 UIKit       6558145124 -[UIWindow(AdditionalLayoutSupport) _windowInternalConstraints_sizeDidChange] + 220 
7 UIKit       6553937808 -[UIWindow _setFrame:sendTraitNotifications:] + 436 
8 UIKit       6553925712 __78-[UIWindow _rotateWindowToOrientation:updateStatusBar:duration:skipCallbacks:]_block_invoke1072 + 264 
9 UIKit       6556461676 __58-[_UIWindowRotationAnimationController animateTransition:]_block_invoke + 56 
10 UIKit       6551262980 +[UIView(UIViewAnimationWithBlocks) _setupAnimationWithDuration:delay:view:options:factory:animations:start:animationStateGenerator:completion:] + 508 
11 UIKit       6551360196 +[UIView(UIViewAnimationWithBlocks) animateWithDuration:delay:options:animations:completion:] + 68 
12 UIKit       6556461540 -[_UIWindowRotationAnimationController animateTransition:] + 388 
13 UIKit       6553920912 -[UIWindow _rotateToBounds:withAnimator:transitionContext:] + 800 
14 UIKit       6553924620 -[UIWindow _rotateWindowToOrientation:updateStatusBar:duration:skipCallbacks:] + 1260 
15 UIKit       6553926412 -[UIWindow _setRotatableClient:toOrientation:applyTransformToWindow:updateStatusBar:duration:force:isRotating:] + 360 
16 UIKit       6551563312 -[UIWindow _setRotatableViewOrientation:updateStatusBar:duration:force:] + 144 
17 UIKit       6551529112 __57-[UIWindow _updateToInterfaceOrientation:duration:force:]_block_invoke + 128 
18 UIKit       6551053184 -[UIWindow _updateToInterfaceOrientation:duration:force:] + 400 
19 UIKit       6551051872 -[UIWindow _updateInterfaceOrientationFromDeviceOrientation:] + 332 
20 CoreFoundation     6472590020 __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 20 
21 CoreFoundation     6471791696 _CFXNotificationPost + 2060 
22 Foundation      6487714432 -[NSNotificationCenter postNotificationName:object:userInfo:] + 72 
23 UIKit       6551051060 -[UIDevice setOrientation:animated:] + 360 
24 UIKit       6551050224 -[UIApplication handleEvent:withNewEvent:] + 1632 
25 UIKit       6551048320 -[UIApplication sendEvent:] + 104 
26 UIKit       6551491268 _UIApplicationHandleEvent + 700 
27 GraphicsServices    6633656724 _PurpleEventCallback + 712 
28 GraphicsServices    6633655428 PurpleEventCallback + 44 
29 CoreFoundation     6472661588 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 56 
30 CoreFoundation     6472661428 __CFRunLoopDoSource1 + 436 
31 CoreFoundation     6472653108 __CFRunLoopRun + 1640 
32 CoreFoundation     6471783124 CFRunLoopRunSpecific + 396 
33 GraphicsServices    6633649916 GSEventRunModal + 168 
34 UIKit       6551465792 UIApplicationMain + 1488 
35 project_name     4298267384 main + 108 (main.m:18) 
36 libdyld.dylib     6778251784 start + 4 
+0

這是一個例外,把斷點或啓用殭屍和檢查 –

回答

0

轉到「Breakpoint navigator」並點擊左下角的「+」按鈕並選擇「Add Exception Breakpoint ...」。

這種斷點捕捉所有的異常,所以你可以導航左側的堆棧錯誤,並找出發生了什麼。