Version: 1.2.90 (using KDE 3.2.1, (testing/unstable)) Compiler: gcc version 3.3.3 (Debian) OS: Linux (i686) release 2.4.21 I tried generating code many times wtih many different files, and I seem to always come across the same problem : A system crash occurs. Sometimes the .xmi file is empty ! The common link in all the files is that I have a class "Widget". When I use files without this class "Widget" everything is OK. Unable to show backtrace (Why is that ?) infopol-chris:~/logiciels/kdesdk-040314/umbrello# umbrello: CodeGeneratorFactory created umbrello: Querying languages available umbrello: Looking up generator for language Ada umbrello: Looking up generator for language ActionScript umbrello: Looking up generator for language Cpp umbrello: Looking up generator for language IDL umbrello: Looking up generator for language Java umbrello: Looking up generator for language JavaScript umbrello: Looking up generator for language Perl umbrello: Looking up generator for language PHP umbrello: Looking up generator for language Python umbrello: Looking up generator for language SQL umbrello: Looking up generator for language XMLSchema umbrello: CodeGeneratorFactory created umbrello: Looking up generator for language PHP umbrello: CodeGeneratorFactory created umbrello: Looking up generator for language Cpp umbrello: WARNING: Can't set content: unexpected end of file Line: 1 umbrello: CodeGeneratorFactory created umbrello: Looking up generator for language Cpp
This only happens on diagrams which have been saved then loaded. >Unable to show backtrace (Why is that ?) It's either because the packages were compiled without --debug or because DrKonqui is broken (I suspect the second since I can get a backtrace from gdb but not DrKonqi). #0 0x0811336e in CodeGenerator::getPolicy() (this=0x0) at codegenerator.cpp:183 #1 0x0820c07e in CodeGenerationWizard::showPage(QWidget*) (this=0xbfffeab0, page=0x8455838) at umbrello/dialogs/codegenerationwizard.cpp:167 #2 0x40d7b1ff in QWizard::next() () from /usr/lib/libqt-mt.so.3 #3 0x40f16412 in QWizard::qt_invoke(int, QUObject*) () from /usr/lib/libqt-mt.so.3 #4 0x08224163 in CodeGenerationWizardBase::qt_invoke(int, QUObject*) () at qsizepolicy.h:95 #5 0x0820c876 in CodeGenerationWizard::qt_invoke(int, QUObject*) (this=0xbfffeab0, _id=56, _o=0xbfffe160) at codegenerationwizard.moc:103 #6 0x40bced9c in QObject::activate_signal(QConnectionList*, QUObject*) () from /usr/lib/libqt-mt.so.3 #7 0x40bcebd4 in QObject::activate_signal(int) () from /usr/lib/libqt-mt.so.3 #8 0x40ef32fe in QButton::clicked() () from /usr/lib/libqt-mt.so.3 #9 0x40c5d6ea in QButton::mouseReleaseEvent(QMouseEvent*) () from /usr/lib/libqt-mt.so.3 #10 0x40c03da7 in QWidget::event(QEvent*) () from /usr/lib/libqt-mt.so.3
> The common link in all the files is that I have a class "Widget". > When I use files without this class "Widget" everything is OK. Could you create an attachment that solicits the bevahiour? Also, please list the exact steps required to get the crash. Thanks.
According to the backtrace, the document (m_doc) of the CodeGenerationWizard has no CodeGenerator set, so in showPage() a null pointer is accessed in line CodeGenerationPolicy *policy = m_doc->getCurrentCodeGenerator()->getPolicy() Is it enough to check for null pointer here or is the null pointer itself the bug? Ciao, Tobias
CVS commit by tokoe: Set the code generator, otherwise you'll get a lot of crashes all over the application. CCMAIL:77645-done@bugs.kde.org M +2 -0 uml.cpp 1.119 --- kdesdk/umbrello/umbrello/uml.cpp #1.118:1.119 @@ -632,4 +632,5 @@ void UMLApp::slotFileOpen() { } + setGenerator(createGenerator()); slotUpdateViews(); loading = false; @@ -655,4 +656,5 @@ void UMLApp::slotFileOpenRecent(const KU loading = false; + setGenerator(createGenerator()); slotUpdateViews(); slotStatusMsg(i18n("Ready."));