Application: umbrello (2.4.1) KDE Platform Version: 4.4.1 (KDE 4.4.1) Qt Version: 4.6.2 Operating System: Linux 2.6.32-17-generic i686 Distribution: Ubuntu lucid (development branch) -- Information about the crash: Was testing the code generation wizard using a simple test class. Had already generated a Java and PHP class (without closing the wizard), and when I tested C# it crashed. Can't seem to reproduce it though and the back-trace doesn't tell me much. Perhaps it makes more sense to somebody more familiar with the code. Note, I am running this on Gnome (Ubuntu 10.04 alpha), if that matters. The crash does not seem to be reproducible. -- Backtrace: Application: Umbrello UML Modeller (umbrello), signal: Segmentation fault [KCrash Handler] #6 UMLObject::getUMLPackage (this=0xbfdab538) at ../../../umbrello/umbrello/umlobject.cpp:606 #7 0x08486965 in CSharpWriter::writeOperations (this=0xab0f080, opList=..., cs=..., isInterface=false, isOverride=false, generateErrorStub=true) at ../../../umbrello/umbrello/codegenerators/csharp/csharpwriter.cpp:474 #8 0x08487948 in CSharpWriter::writeOperations (this=0xab0f080, c=0xa8e6800, cs=...) at ../../../umbrello/umbrello/codegenerators/csharp/csharpwriter.cpp:352 #9 0x0848a2bb in CSharpWriter::writeClass (this=0xab0f080, c=0xa8e6800) at ../../../umbrello/umbrello/codegenerators/csharp/csharpwriter.cpp:298 #10 0x0826d2db in SimpleCodeGenerator::writeCodeToFile (this=0xab0f080, concepts=...) at ../../../umbrello/umbrello/codegenerators/simplecodegenerator.cpp:288 #11 0x080f9c9d in CodeGenStatusPage::generateCode (this=0xb021288) at ../../../umbrello/umbrello/codegenwizard/codegenstatuspage.cpp:119 #12 0x080fab41 in CodeGenStatusPage::qt_metacall (this=0xb021288, _c=QMetaObject::InvokeMetaMethod, _id=30, _a=0xbfdab978) at ./codegenstatuspage.moc:76 #13 0x0479ec3a in QMetaObject::metacall (object=0xb021288, cl=177579952, idx=30, argv=0xbfdab978) at kernel/qmetaobject.cpp:237 #14 0x047ad375 in QMetaObject::activate (sender=0xb02ee80, m=0x25af8c4, local_signal_index=2, argv=0xbfdab978) at kernel/qobject.cpp:3293 #15 0x0239f2d9 in QAbstractButton::clicked (this=0xb02ee80, _t1=false) at .moc/release-shared/moc_qabstractbutton.cpp:206 #16 0x0207ece9 in QAbstractButtonPrivate::emitClicked (this=0xb02ee98) at widgets/qabstractbutton.cpp:546 #17 0x0207fb34 in QAbstractButtonPrivate::click (this=0xb02ee98) at widgets/qabstractbutton.cpp:539 #18 0x0207fdee in QAbstractButton::mouseReleaseEvent (this=0xb02ee80, e=0xbfdac0b0) at widgets/qabstractbutton.cpp:1121 #19 0x01cd2788 in QWidget::event (this=0xb02ee80, event=0xbfdac0b0) at kernel/qwidget.cpp:7998 #20 0x0207eb8e in QAbstractButton::event (this=0xb02ee80, e=0xab0f080) at widgets/qabstractbutton.cpp:1080 #21 0x02129032 in QPushButton::event (this=0xb02ee80, e=0xbfdac0b0) at widgets/qpushbutton.cpp:679 #22 0x01c744dc in QApplicationPrivate::notify_helper (this=0xa308728, receiver=0xb02ee80, e=0xbfdac0b0) at kernel/qapplication.cpp:4300 #23 0x01c7b9f7 in QApplication::notify (this=0xbfdadb90, receiver=0xb02ee80, e=0xbfdac0b0) at kernel/qapplication.cpp:3865 #24 0x00e58f3a in KApplication::notify (this=0xbfdadb90, receiver=0xb02ee80, event=0xbfdac0b0) at ../../kdeui/kernel/kapplication.cpp:302 #25 0x047999db in QCoreApplication::notifyInternal (this=0xbfdadb90, receiver=0xb02ee80, event=0xbfdac0b0) at kernel/qcoreapplication.cpp:704 #26 0x01c7a952 in QCoreApplication::sendEvent (receiver=0xb02ee80, event=0xbfdac0b0, alienWidget=0xb02ee80, nativeWidget=0xaebbf58, buttonDown=0x25b8058, lastMouseReceiver=..., spontaneous=true) at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:215 #27 QApplicationPrivate::sendMouseEvent (receiver=0xb02ee80, event=0xbfdac0b0, alienWidget=0xb02ee80, nativeWidget=0xaebbf58, buttonDown=0x25b8058, lastMouseReceiver=..., spontaneous=true) at kernel/qapplication.cpp:2965 #28 0x01d06018 in QETWidget::translateMouseEvent (this=0xaebbf58, event=0xbfdac5cc) at kernel/qapplication_x11.cpp:4368 #29 0x01d054a1 in QApplication::x11ProcessEvent (this=0xbfdadb90, event=0xbfdac5cc) at kernel/qapplication_x11.cpp:3379 #30 0x01d3443a in x11EventSourceDispatch (s=0xa30b968, callback=0, user_data=0x0) at kernel/qguieventdispatcher_glib.cpp:146 #31 0x010cd645 in g_main_context_dispatch () from /lib/libglib-2.0.so.0 #32 0x010d1338 in ?? () from /lib/libglib-2.0.so.0 #33 0x010d1518 in g_main_context_iteration () from /lib/libglib-2.0.so.0 #34 0x047c5565 in QEventDispatcherGlib::processEvents (this=0xa2eb1c8, flags=...) at kernel/qeventdispatcher_glib.cpp:412 #35 0x01d33f65 in QGuiEventDispatcherGlib::processEvents (this=0xa2eb1c8, flags=...) at kernel/qguieventdispatcher_glib.cpp:204 #36 0x04797ff9 in QEventLoop::processEvents (this=0xbfdac8c0, flags=) at kernel/qeventloop.cpp:149 #37 0x0479844a in QEventLoop::exec (this=0xbfdac8c0, flags=...) at kernel/qeventloop.cpp:201 #38 0x021b3333 in QDialog::exec (this=0xae83208) at dialogs/qdialog.cpp:546 #39 0x086cc11f in UMLApp::generationWizard (this=0xa487488) at ../../../umbrello/umbrello/uml.cpp:1965 #40 0x086dd10a in UMLApp::qt_metacall (this=0xa487488, _c=QMetaObject::InvokeMetaMethod, _id=0, _a=0xbfdaca48) at ./uml.moc:229 #41 0x0479ec3a in QMetaObject::metacall (object=0xa487488, cl=177579952, idx=48, argv=0xbfdaca48) at kernel/qmetaobject.cpp:237 #42 0x047ad375 in QMetaObject::activate (sender=0xa4cfb20, m=0x259cd58, local_signal_index=1, argv=0xbfdaca48) at kernel/qobject.cpp:3293 #43 0x01c6dbd9 in QAction::triggered (this=0xa4cfb20, _t1=false) at .moc/release-shared/moc_qaction.cpp:263 #44 0x01c6fdcc in QAction::activate (this=0xa4cfb20, event=QAction::Trigger) at kernel/qaction.cpp:1255 #45 0x0211344c in QMenuPrivate::activateCausedStack (this=0xa59c818, causedStack=..., action=0xa4cfb20, action_e=QAction::Trigger, self=true) at widgets/qmenu.cpp:1011 #46 0x021198fb in QMenuPrivate::activateAction (this=0xa59c818, action=0xa4cfb20, action_e=QAction::Trigger, self=<value optimized out>) at widgets/qmenu.cpp:1103 #47 0x0211a907 in QMenu::mouseReleaseEvent (this=0xa5a06c8, e=0xbfdad2e0) at widgets/qmenu.cpp:2312 #48 0x00f4ef65 in KMenu::mouseReleaseEvent (this=0xa5a06c8, e=0xbfdad2e0) at ../../kdeui/widgets/kmenu.cpp:471 #49 0x01cd2788 in QWidget::event (this=0xa5a06c8, event=0xbfdad2e0) at kernel/qwidget.cpp:7998 #50 0x0211bf0c in QMenu::event (this=0xa5a06c8, e=0xbfdad2e0) at widgets/qmenu.cpp:2414 #51 0x01c744dc in QApplicationPrivate::notify_helper (this=0xa308728, receiver=0xa5a06c8, e=0xbfdad2e0) at kernel/qapplication.cpp:4300 #52 0x01c7b9f7 in QApplication::notify (this=0xbfdadb90, receiver=0xa5a06c8, e=0xbfdad2e0) at kernel/qapplication.cpp:3865 #53 0x00e58f3a in KApplication::notify (this=0xbfdadb90, receiver=0xa5a06c8, event=0xbfdad2e0) at ../../kdeui/kernel/kapplication.cpp:302 #54 0x047999db in QCoreApplication::notifyInternal (this=0xbfdadb90, receiver=0xa5a06c8, event=0xbfdad2e0) at kernel/qcoreapplication.cpp:704 #55 0x01c7a952 in QCoreApplication::sendEvent (receiver=0xa5a06c8, event=0xbfdad2e0, alienWidget=0x0, nativeWidget=0xa5a06c8, buttonDown=0x25b8058, lastMouseReceiver=..., spontaneous=true) at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:215 #56 QApplicationPrivate::sendMouseEvent (receiver=0xa5a06c8, event=0xbfdad2e0, alienWidget=0x0, nativeWidget=0xa5a06c8, buttonDown=0x25b8058, lastMouseReceiver=..., spontaneous=true) at kernel/qapplication.cpp:2965 #57 0x01d0655f in QETWidget::translateMouseEvent (this=0xa5a06c8, event=0xbfdad7fc) at kernel/qapplication_x11.cpp:4302 #58 0x01d054a1 in QApplication::x11ProcessEvent (this=0xbfdadb90, event=0xbfdad7fc) at kernel/qapplication_x11.cpp:3379 #59 0x01d3443a in x11EventSourceDispatch (s=0xa30b968, callback=0, user_data=0x0) at kernel/qguieventdispatcher_glib.cpp:146 #60 0x010cd645 in g_main_context_dispatch () from /lib/libglib-2.0.so.0 #61 0x010d1338 in ?? () from /lib/libglib-2.0.so.0 #62 0x010d1518 in g_main_context_iteration () from /lib/libglib-2.0.so.0 #63 0x047c5565 in QEventDispatcherGlib::processEvents (this=0xa2eb1c8, flags=...) at kernel/qeventdispatcher_glib.cpp:412 #64 0x01d33f65 in QGuiEventDispatcherGlib::processEvents (this=0xa2eb1c8, flags=...) at kernel/qguieventdispatcher_glib.cpp:204 #65 0x04797ff9 in QEventLoop::processEvents (this=0xbfdadaf4, flags=) at kernel/qeventloop.cpp:149 #66 0x0479844a in QEventLoop::exec (this=0xbfdadaf4, flags=...) at kernel/qeventloop.cpp:201 #67 0x0479c63f in QCoreApplication::exec () at kernel/qcoreapplication.cpp:981 #68 0x01c74577 in QApplication::exec () at kernel/qapplication.cpp:3579 #69 0x086ac5d5 in main (argc=3, argv=0xbfdadd44) at ../../../umbrello/umbrello/main.cpp:111 Reported using DrKonqi
(In reply to Atli Þór Jónsson from comment #0) > #6 UMLObject::getUMLPackage (this=0xbfdab538) at ../../../umbrello/umbrello/umlobject.cpp:606 This call is performed from QString CSharpWriter::makeLocalTypeName(UMLClassifierListItem *cl) { UMLPackage *p = cl->getType()->getUmlPackage(); where UMLClassifier * UMLClassifierListItem::getType() const is defined as { return static_cast<UMLClassifier*>(m_pSecondary); } m_pSecondary could be zero, but isn't checked against in the statement UMLPackage *p = cl->getType()->getUmlPackage();
Git commit 2801735fd954d76c40194f4318b07c656b7bd550 by Ralf Habacker. Committed on 18/08/2015 at 19:34. Pushed by habacker into branch 'Applications/15.08'. Fix 'Umbrello crashed when generating C# code' in CSharpWriter::makeLocalTypeName(). This commit contains a fix for the same case in ValaWriter::makeLocalTypeName(). FIXED-IN:2.17.1 (KDE Applications 15.08.1) M +7 -7 umbrello/codegenerators/csharp/csharpwriter.cpp M +7 -6 umbrello/codegenerators/vala/valawriter.cpp http://commits.kde.org/umbrello/2801735fd954d76c40194f4318b07c656b7bd550