Details
-
Bug
-
Resolution: Invalid
-
Not Evaluated
-
None
-
4.6.0
-
None
-
None
-
OS X 10.6.2, MacPorts 1.8.2, Qt 4.6.0, XCode 3.2.1
Description
What we did:
We are trying to port the application Licq (http://www.licq.org/) over to Mac OS X, using OS X 10.6, using a natively compiled 64 bit version of Qt 4.6.0 for OS X, which is based on Cocoa. The Qt based GUI is implemented as a plugin that is run from a seperate thread and loaded dynamically during runtime.
What we expected to happen:
As with our Linux and BSD versions, we expected the program to load and run correctly.
What we got instead:
The application crashes with the following message:
2010-01-15 16:37:13.083 licq[46770:2403] *** Assertion failure in +[NSUndoManager _endTopLevelGroupings], /SourceCache/Foundation/Foundation-751.14/Misc.subproj/NSUndoManager.m:271
2010-01-15 16:37:13.085 licq[46770:2403] +[NSUndoManager(NSInternal) _endTopLevelGroupings] is only safe to invoke on the main thread.
2010-01-15 16:37:13.086 licq[46770:2403] *** Assertion failure in +[NSUndoManager _endTopLevelGroupings], /SourceCache/Foundation/Foundation-751.14/Misc.subproj/NSUndoManager.m:271
Qt has caught an exception thrown from an event handler. Throwing
exceptions from an event handler is not supported in Qt. You must
reimplement QApplication::notify() and catch all exceptions there.
The important line is I think the second one. The Qt app from the plugin is not created within the main thread, which is fine for the other platforms, but seemingly not on OS X. We used to use the Carbon version of Qt, but since we now use a 64 bit environment for development, that is NOT an option anymore. So we are looking for a workaround, since limiting Qt only to the main thread is not an option either.