Xcode 4: Crash on Breakpoint Navigator - xcode4

If I click on the "activate/deactivate breakpoints" button in Xcode 4.0.2 and then try to add a breakpoint, no breakpoints are generated. Then if I click on the "Breakpoint navigator" Xcode crashes. So, obviously something's not right. Here's the crash report:
UNCAUGHT EXCEPTION (NSInvalidArgumentException): -[NSNull countByEnumeratingWithState:objects:count:]: unrecognized selector sent to instance 0x7fff701bbfa0
UserInfo: (null)
Hints:
0: Replacement view is installing: <IDEBreakpointNavigator: 0x201f19160 representing: <DVTExtension 0x20051eae0: Breakpoint Navigator (Xcode.IDEKit.Navigator.Breakpoints) v0.1>>
Backtrace:
0 0x00007fff80a57796 __exceptionPreprocess (in CoreFoundation)
1 0x00007fff822fd0f3 objc_exception_throw (in libobjc.A.dylib)
2 0x00007fff80ab1110 +[NSObject(NSObject) doesNotRecognizeSelector:] (in CoreFoundation)
3 0x00007fff80a2991f ___forwarding___ (in CoreFoundation)
4 0x00007fff80a25a68 _CF_forwarding_prep_0 (in CoreFoundation)
5 0x00000001175c2f13 -[IDEBreakpointNavigator _handleBreakpointsAdded:] (in DebuggerUI)
6 0x00007fff846a2f26 -[NSObject(NSKeyValueObserverRegistration) _addObserver:forProperty:options:context:] (in Foundation)
7 0x00007fff846a19cc -[NSObject(NSKeyValueObserverRegistration) addObserver:forKeyPath:options:context:] (in Foundation)
8 0x000000010001d9b5 -[DVTObservingBlockToken _setupObservingWithOptions:] (in DVTFoundation)
9 0x000000010001d8d3 -[DVTObservingBlockToken setHandlerBlock:forKeyPath:options:] (in DVTFoundation)
10 0x000000010001d6d8 -[NSObject(DVTObservingConvenience) dvt_newObserverForKeyPath:options:owner:withHandlerBlock:] (in DVTFoundation)
11 0x000000010001d662 -[NSObject(DVTObservingConvenience) dvt_newObserverForKeyPath:options:withHandlerBlock:] (in DVTFoundation)
12 0x00000001175c1a9d -[IDEBreakpointNavigator viewDidInstall] (in DebuggerUI)
13 0x00000001001d88a8 -[DVTControllerContentView _viewDidInstall] (in DVTKit)
14 0x00000001001d832a -[DVTControllerContentView viewDidMoveToWindow] (in DVTKit)
15 0x00007fff811f9b4f -[NSView _setWindow:] (in AppKit)
16 0x00007fff81202672 -[NSView addSubview:] (in AppKit)
17 0x00000001001de335 __42-[DVTReplacementView _setupViewController]_block_invoke_0 (in DVTKit)
18 0x0000000100031afd DVTInvokeWithFailureHint (in DVTFoundation)
19 0x00000001001de1d6 -[DVTReplacementView _setupViewController] (in DVTKit)
20 0x00000001001de0b8 -[DVTReplacementView installedViewController] (in DVTKit)
21 0x00000001001e8ff1 -[DVTReplacementView layoutTopDown] (in DVTKit)
22 0x00000001001d90e6 __84+[DVTAutoLayoutView _recursivelyLayoutSubviewsOfView:populatingSetWithLaidOutViews:]_block_invoke_0 (in DVTKit)
23 0x00000001001d918f __84+[DVTAutoLayoutView _recursivelyLayoutSubviewsOfView:populatingSetWithLaidOutViews:]_block_invoke_0 (in DVTKit)
24 0x00000001001d918f __84+[DVTAutoLayoutView _recursivelyLayoutSubviewsOfView:populatingSetWithLaidOutViews:]_block_invoke_0 (in DVTKit)
25 0x00000001001d918f __84+[DVTAutoLayoutView _recursivelyLayoutSubviewsOfView:populatingSetWithLaidOutViews:]_block_invoke_0 (in DVTKit)
26 0x00000001001d918f __84+[DVTAutoLayoutView _recursivelyLayoutSubviewsOfView:populatingSetWithLaidOutViews:]_block_invoke_0 (in DVTKit)
27 0x00000001001d918f __84+[DVTAutoLayoutView _recursivelyLayoutSubviewsOfView:populatingSetWithLaidOutViews:]_block_invoke_0 (in DVTKit)
28 0x00000001001d918f __84+[DVTAutoLayoutView _recursivelyLayoutSubviewsOfView:populatingSetWithLaidOutViews:]_block_invoke_0 (in DVTKit)
29 0x00000001001d8f33 +[DVTAutoLayoutView _recursivelyLayoutSubviewsOfView:populatingSetWithLaidOutViews:] (in DVTKit)
30 0x00000001001d8ce1 -[DVTAutoLayoutView viewWillDraw] (in DVTKit)
31 0x00007fff812d8e19 -[NSView viewWillDraw] (in AppKit)
32 0x00007fff812d8e19 -[NSView viewWillDraw] (in AppKit)
33 0x00007fff812d8e19 -[NSView viewWillDraw] (in AppKit)
34 0x00007fff812d8e19 -[NSView viewWillDraw] (in AppKit)
35 0x00007fff812d83ca -[NSView _sendViewWillDrawInRect:clipRootView:suppressRecursion:] (in AppKit)
36 0x00007fff81253b5d -[NSView displayIfNeeded] (in AppKit)
37 0x00007fff8124ea46 _handleWindowNeedsDisplay (in AppKit)
38 0x00007fff80a16b37 __CFRunLoopDoObservers (in CoreFoundation)
39 0x00007fff809f2464 __CFRunLoopRun (in CoreFoundation)
40 0x00007fff809f1dbf CFRunLoopRunSpecific (in CoreFoundation)
41 0x00007fff81c057ee RunCurrentEventLoopInMode (in HIToolbox)
42 0x00007fff81c05551 ReceiveNextEventCommon (in HIToolbox)
43 0x00007fff81c054ac BlockUntilNextEventMatchingListInMode (in HIToolbox)
44 0x00007fff81223e64 _DPSNextEvent (in AppKit)
45 0x00007fff812237a9 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] (in AppKit)
46 0x00007fff811e948b -[NSApplication run] (in AppKit)
47 0x00007fff811e21a8 NSApplicationMain (in AppKit)
48 0x0000000100000eec
49 0x0000000000000002
Anyone else come across this?
Thanks,
Shawn

Related

SIGABRT error in Xamarin.Forms app

I have a Xamarin.Forms application that we are ready to deploy to production but I keep getting this SIGABRT error.
I've setup a HockeyApp to monitor any crash that may occur.
It seems that this error keeps on appearing crash or not.
I've included the upper portion of the stack trace that I don't know how to interpret.
Can any body help me interpret what this is?
Thank you
Incident Identifier: C2FA8822-C1D4-4ECA-BD30-2D38D10A7AF2
CrashReporter Key: 90F6BDB6-4B7A-4F69-BA47-74027B6E607D
Hardware Model: iPhone7,2
Process: MyCase.iOS [1687]
Path: /var/containers/Bundle/Application/23343C73-BA08-4F6F-8FD9-99472E20F2A3/MyCase.iOS.app/MyCase.iOS
Identifier: <Bundle Id> (omitted for privacy reasons)
Version: 2.93 (2.93)
Code Type: ARM-64
Parent Process: ??? [1]
Date/Time: 2016-09-20T00:01:29Z
Launch Time: 2016-09-19T22:20:17Z
OS Version: iPhone OS 9.3.5 (13G36)
Report Version: 104
Exception Type: SIGABRT
Exception Codes: #0 at 0x181ef011c
Crashed Thread: 0
Application Specific Information:
*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'This app can't run in background'
Last Exception Backtrace:
0 CoreFoundation 0x0000000182356db0 0x18222c000 + 1224112
1 libobjc.A.dylib 0x00000001819bbf80 0x1819b4000 + 32640
2 CoreFoundation 0x0000000182356c80 0x18222c000 + 1223808
3 Foundation 0x0000000182cdc154 0x182c38000 + 672084
4 TestLib.dylib 0x00000001016b7d88 0x1016b0000 + 32136
5 UIKit 0x000000018777201c 0x1874a4000 + 2940956
6 UIKit 0x0000000187777ba4 0x1874a4000 + 2964388
7 UIKit 0x0000000187777a80 0x1874a4000 + 2964096
8 UIKit 0x000000018776170c 0x1874a4000 + 2873100
9 UIKit 0x0000000187761394 0x1874a4000 + 2872212
10 FrontBoardServices 0x0000000183cf77ac 0x183cd0000 + 161708
11 FrontBoardServices 0x0000000183cf7618 0x183cd0000 + 161304
12 FrontBoardServices 0x0000000183cf79c8 0x183cd0000 + 162248
13 CoreFoundation 0x000000018230d09c 0x18222c000 + 921756
14 CoreFoundation 0x000000018230cb30 0x18222c000 + 920368
15 CoreFoundation 0x000000018230a830 0x18222c000 + 911408
16 CoreFoundation 0x0000000182234c50 0x18222c000 + 35920
17 GraphicsServices 0x0000000183b1c088 0x183b10000 + 49288
18 UIKit 0x0000000187522088 0x1874a4000 + 516232
19 MyCase.iOS 0x0000000100d7a514 0x100020000 + 14001428
20 MyCase.iOS 0x0000000100ccb40c 0x100020000 + 13284364
21 MyCase.iOS 0x0000000100ccb3cc 0x100020000 + 13284300
22 MyCase.iOS 0x0000000100295454 0x100020000 + 2577492
23 MyCase.iOS 0x0000000100729554 0x100020000 + 7378260
24 MyCase.iOS 0x000000010018f1c4 0x100020000 + 1503684
25 MyCase.iOS 0x00000001001f7f94 0x100020000 + 1933204
26 MyCase.iOS 0x00000001001fc948 0x100020000 + 1952072
27 MyCase.iOS 0x0000000100294da0 0x100020000 + 2575776
28 MyCase.iOS 0x00000001013cf510 0x100020000 + 20641040
29 ??? 0x0000000181dd28b8 0x0 + 0
Thread 0 Crashed:
0 libsystem_kernel.dylib 0x0000000181ef011c 0x181ed4000 + 114972
1 libsystem_c.dylib 0x0000000181e61dc8 0x181e00000 + 400840
2 MyCase.iOS 0x0000000100135014 0x100020000 + 1134612
3 CoreFoundation 0x0000000182357138 0x18222c000 + 1225016
4 libobjc.A.dylib 0x00000001819bc23c 0x1819b4000 + 33340
5 MyCase.iOS 0x0000000100122d50 0x100020000 + 1060176
6 libc++abi.dylib 0x00000001819aef44 0x181994000 + 110404
7 libc++abi.dylib 0x00000001819aeb10 0x181994000 + 109328
8 libobjc.A.dylib 0x00000001819bc120 0x1819b4000 + 33056
9 CoreFoundation 0x0000000182234cf8 0x18222c000 + 36088
10 GraphicsServices 0x0000000183b1c088 0x183b10000 + 49288
11 UIKit 0x0000000187522088 0x1874a4000 + 516232
12 MyCase.iOS 0x0000000100d7a514 0x100020000 + 14001428
13 MyCase.iOS 0x0000000100ccb40c 0x100020000 + 13284364
14 MyCase.iOS 0x0000000100ccb3cc 0x100020000 + 13284300
15 MyCase.iOS 0x0000000100295454 0x100020000 + 2577492
16 MyCase.iOS 0x0000000100729554 0x100020000 + 7378260
17 MyCase.iOS 0x000000010018f1c4 0x100020000 + 1503684
18 MyCase.iOS 0x00000001001f7f94 0x100020000 + 1933204
19 MyCase.iOS 0x00000001001fc948 0x100020000 + 1952072
20 MyCase.iOS 0x0000000100294da0 0x100020000 + 2575776
21 MyCase.iOS 0x00000001013cf510 0x100020000 + 20641040
22 ??? 0x0000000181dd28b8 0x0 + 0
I've have had the same error before HockeyApp NuGet package or any NuGet package can have the same error I am not sure if it a Linking error, try to turn off the linker ("Don't link") if that does not work try to use a different version of HockeyApp (3.7.1.0) works fine for me.
The problem may persist tho, if you are handling code inside the AppDelegate or the MainActivity check the App lifecycle (OnResume, OnStart, OnSleep and so on).
I can see in the logs: "This app can't run in background" So verify and double check if your code is handling correctly the App Lifecycle and transitions, it may be related to a lot of things (notifications, components, NuGets, Lifecycle, threads, async/await calls)
Hope this helps.

Qt 5.5 and OpenGL: QVertexArrayObject::create() calls QPainter::drawimage()?

I understand that for any of the Qt OpenGL convenience classes to correctly be initialized and used, they must be called with a valid current context. So, I designed my classes to be initialized from my overloaded QOpenGLWidget::initializeGL() function, in which the documentation states the context is created and made current (albeit without a framebuffer).
However, when initializeGL() attempts to initialize one of my subclasses MeshObject, specifically calling the function QOpenGLVertexArrayObject::create(), the program crashes with the message
Read access violation at 0x0
Going through with a debugger, note the call stack:
There are calls being made to QPainter::drawImage, which would surely fail as there is no framebuffer present.
But why is there a QPainter::drawImage call happening when I try to create a vertexArrayObject? Surely this function should have no involvement with painting to the screen.
ALthough the documentation also states that QOpenGLVertexArrayObjects will only work on some OpenGL ES 2.0 platforms, vbuffer.create() causes exactly the same scenario to occur, and I've already used QOpenGLVertexArrayObjects on this exact machine on a previous project with absolutely no problems.
Complete stack trace:
0 QPainter::drawImage Qt5Guid 0x58292a56
1 QPainter::drawImage Qt5Guid 0x5829203c
2 MeshState::initBuffers meshobject.cpp 71 0x2fb793
3 SceneObject::setupObjects sceneobject.cpp 18 0x2fa1eb
4 SceneObject::initialize sceneobject.cpp 12 0x2fa12f
5 OpenGLWidget::initializeGL openglwidget.cpp 34 0x2f8ecf
6 QAbstractScrollArea::setHorizontalScrollBar Qt5Widgetsd 0x587a9859
7 QAbstractScrollArea::setHorizontalScrollBar Qt5Widgetsd 0x587a86da
8 QAbstractScrollArea::setHorizontalScrollBar Qt5Widgetsd 0x58770104
9 QAbstractScrollArea::setHorizontalScrollBar Qt5Widgetsd 0x587a8850
10 QAbstractScrollArea::setHorizontalScrollBar Qt5Widgetsd 0x5872548e
11 QAbstractScrollArea::setHorizontalScrollBar Qt5Widgetsd 0x587235f5
12 QSortFilterProxyModel::mapToSource Qt5Cored 0x591b6b47
13 QSortFilterProxyModel::mapToSource Qt5Cored 0x591bf379
14 QAbstractScrollArea::setHorizontalScrollBar Qt5Widgetsd 0x5877a3a3
15 QAbstractScrollArea::setHorizontalScrollBar Qt5Widgetsd 0x5877a618
16 QAbstractScrollArea::setHorizontalScrollBar Qt5Widgetsd 0x5876be41
17 QAbstractScrollArea::setHorizontalScrollBar Qt5Widgetsd 0x5876c0bb
18 QAbstractScrollArea::setHorizontalScrollBar Qt5Widgetsd 0x58779441
19 QAbstractScrollArea::setHorizontalScrollBar Qt5Widgetsd 0x5877a62e
20 QAbstractScrollArea::setHorizontalScrollBar Qt5Widgetsd 0x5876be41
21 QAbstractScrollArea::setHorizontalScrollBar Qt5Widgetsd 0x5876c0bb
22 main main.cpp 10 0x2f3419
23 WinMain qtmain_win.cpp 113 0x2fdcdd
24 __tmainCRTStartup crtexe.c 618 0x2fd0bf
25 WinMainCRTStartup crtexe.c 466 0x2fce7d
26 BaseThreadInitThunk KERNEL32 0x772e38f4
27 __RtlUserThreadStart ntdll 0x77865de3
28 _RtlUserThreadStart ntdll 0x77865dae

Run model on each column and save each prediction output

I am trying to compile a code that runs a model on each column and saves each prediction into a data.frame.
I am probably missing a basic step because the result only saves data for the last prediction. It would be great if someone could give me a tip.
Here is the code:
for(i in 1:ncol(temp[,1:101])){
pred=(exp(predict(gam(temp[,i]~s(w),gamma=1.4,data=temp))))
prediction[i]<- as.data.frame(cbind(pred=pred))
}
Here is a short look of the data and result:
temp2
tdat.V1 tdat.V2 tdat.V3 tdat.V4 tdat.V5 w
9 0.2468596 0.2468596 -0.47226384 -0.47226384 -0.69767176 9
10 -0.3298719 -0.3298719 -0.61766160 -0.61766160 -1.05190065 10
11 0.2636122 0.2636122 -0.16966523 -0.16966523 -0.98531224 11
12 1.1036205 1.1036205 0.46601526 0.46601526 -0.35346974 12
13 1.1337664 1.1337664 -0.31946816 -0.31946816 -0.78722896 13
14 1.0441290 1.0441290 -0.19397040 -0.19397040 -0.99997758 14
15 0.5904416 0.5904416 -0.49903362 -0.49903362 -1.29327665 15
16 0.2704478 0.2704478 -0.33188601 -0.33188601 -0.89020267 16
17 0.4905354 0.4905354 0.26849660 0.26849660 -0.22608949 17
18 1.4072215 1.4072215 1.43372101 1.43372101 0.74552152 18
19 -0.3510362 -0.3510362 -0.65455175 -0.65455175 -0.67979925 19
20 -0.9471780 -0.9471780 -0.99449245 -0.99449245 -0.94800264 20
21 0.5601007 0.5601007 -0.41078889 -0.41078889 -0.70911666 21
22 0.6337811 0.6337811 0.11769665 0.11769665 -0.37718872 22
23 1.1154420 1.1154420 0.52692499 0.52692499 0.26777430 23
24 0.1314404 0.1314404 0.02146546 0.02146546 -0.03748099 24
25 0.2262661 0.2262661 0.14216196 0.14216196 -0.19273456 25
26 1.7767008 1.7767008 1.19683315 1.19683315 0.55529405 26
27 2.0070761 2.0070761 1.70737151 1.70737151 0.90322033 27
28 2.2252446 2.2252446 1.35160191 1.35160191 0.98155994 28
29 1.7452878 1.7452878 0.86052298 0.86052298 1.27898872 29
30 0.2071554 0.2071554 0.55612163 0.55612163 0.64726184 30
31 1.7144228 1.7144228 0.74949354 0.74949354 0.42433658 31
32 0.2533343 0.2533343 -0.11861726 -0.11861726 -0.63511376 32
33 0.6176735 0.6176735 0.29274750 0.29274750 -0.20402280 33
34 1.0868382 1.0868382 1.19325652 1.19325652 1.57309478 34
35 1.7051584 1.7051584 0.00151082 0.00151082 -0.95416617 35
> for(i in 1:ncol(temp2[,1:4])){
+
+ pred=(exp(predict(gam(temp2[,i]~s(w),gamma=1.4,data=temp2))))
+ prediction <- as.data.frame(cbind(pred=pred))
+ }
> print(prediction)
pred
9 0.6969407
10 0.7291379
11 0.7628225
12 0.7980632
13 0.8349320
14 0.8735040
15 0.9138580
16 0.9560762
17 1.0002448
18 1.0464540
19 1.0947979
20 1.1453751
21 1.1982889
22 1.2536473
23 1.3115630
24 1.3721544
25 1.4355449
26 1.5018639
27 1.5712468
28 1.6438349
29 1.7197765
30 1.7992264
31 1.8823468
32 1.9693071
33 2.0602847
34 2.1554654
35 2.2550432

As soon as I add a project to XCode 4.0.2 it crashes

It gives this error:
ASSERTION FAILURE in /SourceCache/IDEXcode3ProjectSupport/IDEXcode3ProjectSupport-269/Xcode3Sources/XcodeIDE/Frameworks/DevToolsBase/pbxcore/PBXContainerItemProxy.m:268
Details: Assertion failed: _containerPortal == [self container] || ([_containerPortal isKindOfClass:[PBXFileReference class]] && [(PBXFileReference *)_containerPortal container] == [self container])
Object: <PBXContainerItemProxy: 0x2017db420>
Method: -_containerPortal
Thread: <NSThread: 0x200020700>{name = (null), num = 1}
Hints: None
Backtrace:
0 0x0000000100949773 -[IDEAssertionHandler handleFailureInMethod:object:fileName:lineNumber:messageFormat:arguments:] (in IDEKit)
1 0x000000010006d394 _DVTAssertionFailureHandler (in DVTFoundation)
2 0x000000010d4a15c7 -[PBXContainerItemProxy _containerPortal] (in DevToolsCore)
3 0x000000010d3deefb -[PBXArchivingBinding writeValueForObject:toPListArchiver:] (in DevToolsCore)
4 0x000000010d3dde4e -[PBXObject _archiveValuesForArchiveMask:toPListArchiver:] (in DevToolsCore)
5 0x000000010d40b52a -[PBXPListArchiver _archiveObject:asWeakReference:] (in DevToolsCore)
6 0x000000010d40dea8 -[PBXPListArchiver _encodeObject:forKey:asWeakReference:] (in DevToolsCore)
7 0x000000010d3df0b2 -[PBXArchivingBinding writeValueForObject:toPListArchiver:] (in DevToolsCore)
8 0x000000010d3dde4e -[PBXObject _archiveValuesForArchiveMask:toPListArchiver:] (in DevToolsCore)
9 0x000000010d4461c0 -[PBXTargetDependency writeToPListArchiver:] (in DevToolsCore)
10 0x000000010d40b52a -[PBXPListArchiver _archiveObject:asWeakReference:] (in DevToolsCore)
11 0x000000010d40e212 -[PBXPListArchiver _createPListArrayForObjectArray:asWeakReference:] (in DevToolsCore)
12 0x000000010d40ea15 -[PBXPListArchiver _encodeObjectArray:forKey:asWeakReference:] (in DevToolsCore)
13 0x000000010d3df0b2 -[PBXArchivingBinding writeValueForObject:toPListArchiver:] (in DevToolsCore)
14 0x000000010d3dde4e -[PBXObject _archiveValuesForArchiveMask:toPListArchiver:] (in DevToolsCore)
15 0x000000010d40b52a -[PBXPListArchiver _archiveObject:asWeakReference:] (in DevToolsCore)
16 0x000000010d40e212 -[PBXPListArchiver _createPListArrayForObjectArray:asWeakReference:] (in DevToolsCore)
17 0x000000010d40ea15 -[PBXPListArchiver _encodeObjectArray:forKey:asWeakReference:] (in DevToolsCore)
18 0x000000010d3df0b2 -[PBXArchivingBinding writeValueForObject:toPListArchiver:] (in DevToolsCore)
19 0x000000010d3dde4e -[PBXObject _archiveValuesForArchiveMask:toPListArchiver:] (in DevToolsCore)
20 0x000000010d40b52a -[PBXPListArchiver _archiveObject:asWeakReference:] (in DevToolsCore)
21 0x000000010d40c1b7 -[PBXPListArchiver initWithRootObject:delegate:role:] (in DevToolsCore)
22 0x000000010d40c4ac -[PBXPListArchiver initWithRootObject:delegate:] (in DevToolsCore)
23 0x000000010d3e675d -[PBXProject writeToFile:projectFile:userFile:outResultNotification:] (in DevToolsCore)
24 0x000000010d3e6d42 -[PBXProject _writeToFileSystemProjectFile:userFile:checkNeedsRevert:] (in DevToolsCore)
25 0x000000010d3e6df6 -[PBXProject writeToFileSystemProjectFile:userFile:checkNeedsRevert:] (in DevToolsCore)
26 0x000000010d3653ea -[Xcode3Project writeToFilePath:forceWrite:error:] (in Xcode3Core)
27 0x000000010051e47e -[IDEContainer _saveContainerForAction:error:] (in IDEFoundation)
28 0x00007fff8231b7d5 __NSFireTimer (in Foundation)
29 0x00007fff81173be8 __CFRunLoopRun (in CoreFoundation)
30 0x00007fff81171dbf CFRunLoopRunSpecific (in CoreFoundation)
31 0x00007fff823007c4 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] (in Foundation)
32 0x00007fff8234bf36 -[NSRunLoop(NSRunLoop) runUntilDate:] (in Foundation)
33 0x00007fff83a73e0b NSCoreDragReceiveProc (in AppKit)
34 0x00007fff81a8a2c3 DoDropMessage (in HIServices)
35 0x00007fff81a8b4f2 CoreDragMessageHandler (in HIServices)
36 0x00007fff811d95e1 __CFMessagePortPerform (in CoreFoundation)
37 0x00007fff811736e1 __CFRunLoopRun (in CoreFoundation)
38 0x00007fff81171dbf CFRunLoopRunSpecific (in CoreFoundation)
39 0x00007fff84ea67ee RunCurrentEventLoopInMode (in HIToolbox)
40 0x00007fff84ea6551 ReceiveNextEventCommon (in HIToolbox)
41 0x00007fff84ea64ac BlockUntilNextEventMatchingListInMode (in HIToolbox)
42 0x00007fff83732e64 _DPSNextEvent (in AppKit)
43 0x00007fff837327a9 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] (in AppKit)
44 0x00007fff836f848b -[NSApplication run] (in AppKit)
45 0x00007fff836f11a8 NSApplicationMain (in AppKit)
46 0x0000000100000eec
Even worse, though I'd remove that project, crash had occurred repeatedly in my case.
I fixed this problem by editing project.pbxproj(in .xcodeproject file) manually.
Apparently this is due to the new version of XCodeProjects. I found a work around by pre-compiling the library that was causing the issue and then using the linker to link to the .a file. I also had to copy the .a library into the DerivedData path.
The real solution was to remove the project and replace it with an updated project for the new version of XCode.
I fixed it by going back to a backup of the project.pbxproj. After that I removed the library that was causing the issue (reference only). Added the library to the project again and deleted the DerivedData.

QMessageBox segFaulting in Mainwindows slot onlclick

In my qt mobile app I have a list. I have connected list clicked to a slot of main window.
connect(view,SIGNAL(clicked(QModelIndex)),this,SLOT(showMessage()));
void MainWindow::showMessage()
{
QMessageBox::information(this,"info","info",QMessageBox::Ok,0);
}
Now if i put 'QMessageBox::information(this,"info","info",QMessageBox::Ok,0);' in constructor it works.
else it gives segmentation fault.
0 QWidgetPrivate::setParent_sys qwidget_simulator.cpp 207 0x0083195e
1 QWidget::setParent qwidget.cpp 9985 0x00820784
2 QWidget::setParent qwidget.cpp 9942 0x00820508
3 QFocusFramePrivate::update qfocusframe.cpp 72 0x00c337d1
4 QFocusFrame::setWidget qfocusframe.cpp 231 0x00c340aa
5 QS60Style::event qs60style.cpp 3277 0x00b569e2
6 QApplicationPrivate::notify_helper qapplication.cpp 4415 0x007d84b6
7 QApplication::notify qapplication.cpp 3817 0x007d5f0f
8 QCoreApplication::notifyInternal qcoreapplication.cpp 732 0x6a1fe5bc
9 QCoreApplication::sendEvent qcoreapplication.h 215 0x00e3ac02
10 QApplicationPrivate::setFocusWidget qapplication.cpp 2210 0x007d316c
11 QWidget::setFocus qwidget.cpp 6288 0x00819c21
12 QApplication::setActiveWindow qapplication.cpp 2590 0x007d3df8
13 QWidget::activateWindow qwidget_simulator.cpp 601 0x00832c02
14 QWidgetPrivate::show_sys qwidget_simulator.cpp 242 0x00831af4
15 QWidgetPrivate::show_helper qwidget.cpp 7380 0x0081c41d
16 QWidget::setVisible qwidget.cpp 7594 0x0081cbbe
17 QDialog::setVisible qdialog.cpp 739 0x00c60f78
18 QWidget::show qwidget_simulator.cpp 889 0x00833a26
19 QDialog::exec qdialog.cpp 543 0x00c6060f
20 QMessageBoxPrivate::showOldMessageBox qmessagebox.cpp 1906 0x00c7fdab
...
this is the backtrace. what am it doing wrong here?
The slot has to have the same signature as the signal. You can't connect a signal taking a parameter to a slot that's expecting none. Add that QModelIndex parameter to showMessage():
connect(view,SIGNAL(clicked(QModelIndex)),this,SLOT(showMessage(QModelIndex)));
void MainWindow::showMessage(QModelIndex)
{
QMessageBox::information(this,"info","info",QMessageBox::Ok,0);
}
Your signal doesnt have the same signature as your slot:
clicked(QModelIndex)) = Singal.
showMessage() = Slot.
Turn your slot to be: showMessage(QModelIndex)

Resources