[Uml-devel] umbrello 1.1 - 2 different crashes when printing

Joe Van Andel vanandel at atd.ucar.edu
Thu Jan 23 14:49:01 UTC 2003


I compiled 1.1 from source, with gcc 3.2.1 and qt-x11-free-3.1.1

When I try to print, umbrello core dumps, as shown below.

I tried to run both Parasoft's Chaperon and valgrind-1.0.4.  Chaperon 
had an internal error, and valgrind detected a problem with the run-time
startup library setting the locale, and I couldn't find the
real problem, which I suspect is a memory "scribbling" bug.

valgrind output:
Invalid read of size 4
==2872==    at 0x420229B4: (within /lib/i686/libc-2.2.93.so)
==2872==    by 0x4028A4D5: std::ctype<char>::ctype(unsigned short
const*, bool, unsigned)
(/snoopy/granger/build-gcc3.2.1/i686-pc-linux-gnu/libstdc++-v3/include/i686-pc-linux-gnu/bits/ctype_noninline.h:110)
==2872==    by 0x402BAB30:
std::locale::_Impl::_Impl(std::locale::facet**, unsigned, bool)
(/snoopy/granger/build-gcc3.2.1/i686-pc-linux-gnu/libstdc++-v3/include/bits/localefwd.h:394)
==2872==    by 0x4029CCEA: std::locale::classic()
(/net/src/gnu/gcc-3.2.1/libstdc++-v3/libsupc++/new:89)
==2872==    Address 0x0 is not stack'd, malloc'd or free'd

==============================================================

Despite allocating huge amounts of swap, I ran out of memory running 
Electric fence 2.2.2 (http://perens.com/FreeSoftware/)
=============================================================================



Here's the first crash under gdb:


QPtrCollection::Item QGList::first()
838     {
839         if ( firstNode ) {
840             curIndex = 0;
841***             return (curNode=firstNode)->data;
842         }
843         return 0;
844     }

(gdb) print *this
$2 = {<QPtrCollection> = {_vptr.QPtrCollection = 0x53e58955, del_item =
131},
    firstNode = 0x174e, lastNode = 0x1af2c381, curNode = 0x838b0034,
curIndex = 59124,
    numNodes = 1946171523, iterators = 0xf4838b10}

It appears that 'firstNode' has been stepped on.

here is the backtrace.


0x40e38e7e in QGList::first() (this=0x40dbbc7a) at tools/qglist.cpp:840
#1  0x08090f2d in UMLDoc::findView(int) (this=0x817a350, id=7)
      at /net/opt_lnx/qt-x11-free-3.1.1/include/qptrlist.h:94
#2  0x08145aca in DiagramPrintPage::getOptions(QMap<QString, QString>&,
bool) (
      this=0x82d52e0, opts=@0xbfffd810) at diagramprintpage.cpp:95
#3  0x40129cb4 in KPrintDialog::done(int) () from /usr/lib/libkdeprint.so.4
#4  0x40cc8527 in QDialog::accept() (this=0x820be40) at
dialogs/qdialog.cpp:404
#5  0x40ef5ec7 in QDialog::qt_invoke(int, QUObject*) (this=0x820be40,
_id=47, _o=0xbfffd930)
      at .moc/debug-shared-mt/moc_qdialog.cpp:107
#6  0x40561edf in KDialog::qt_invoke(int, QUObject*) () from
/usr/lib/libkdeui.so.4
#7  0x4012ba23 in KPrintDialog::qt_invoke(int, QUObject*) () from
/usr/lib/libkdeprint.so.4
#8  0x40b128ac in QObject::activate_signal(QConnectionList*, QUObject*)
(this=0x82c3c38,
      clist=0x8372c08, o=0xbfffd930) at kernel/qobject.cpp:2212
#9  0x40b12743 in QObject::activate_signal(int) (this=0x82c3c38, signal=4)
      at kernel/qobject.cpp:2186
#10 0x40ecc081 in QButton::clicked() (this=0x82c3c38)
      at .moc/debug-shared-mt/moc_qbutton.cpp:152
#11 0x40bb4324 in QButton::mouseReleaseEvent(QMouseEvent*)
(this=0x82c3c38, e=0xbfffdd50)
      at widgets/qbutton.cpp:808
#12 0x40b546e5 in QWidget::event(QEvent*) (this=0x82c3c38, e=0xbfffdd50)
      at kernel/qwidget.cpp:4334
#13 0x40a9eedd in QApplication::internalNotify(QObject*, QEvent*)
(this=0xbfffebd0,
      receiver=0x82c3c38, e=0xbfffdd50) at kernel/qapplication.cpp:2350
#14 0x40a9e559 in QApplication::notify(QObject*, QEvent*) (this=0xbfffebd0,
      receiver=0x82c3c38, e=0xbfffdd50) at kernel/qapplication.cpp:2159
#15 0x406f39c6 in KApplication::notify(QObject*, QEvent*) () from
/usr/lib/libkdecore.so.4
#16 0x40a37854 in QApplication::sendSpontaneousEvent(QObject*, QEvent*)
(receiver=0x82c3c38,
      event=0xbfffdd50) at kernel/qapplication.h:481
#17 0x40a2feb8 in QETWidget::translateMouseEvent(_XEvent const*)
(this=0x82c3c38,
      event=0xbfffe030) at kernel/qapplication_x11.cpp:4217
#18 0x40a2d968 in QApplication::x11ProcessEvent(_XEvent*)
(this=0xbfffebd0, event=0xbfffe030)
      at kernel/qapplication_x11.cpp:3395
#19 0x40a484bd in QEventLoop::processEvents(unsigned) (this=0x81b1868,
flags=4)
      at kernel/qeventloop_x11.cpp:169
#20 0x40ab6949 in QEventLoop::enterLoop() (this=0x81b1868) at
kernel/qeventloop.cpp:191
#21 0x40a9f0f7 in QApplication::enter_loop() (this=0xbfffebd0)
      at kernel/qapplication.cpp:2503
#22 0x40cc8460 in QDialog::exec() (this=0x820be40) at
dialogs/qdialog.cpp:366
#23 0x4012c59e in KPrinter::setup(QWidget*, QString const&, bool) ()
     from /usr/lib/libkdeprint.so.4
#24 0x0809ea46 in UMLApp::slotFilePrint() (this=0x820be40) at uml.cpp:566
#25 0x080e0808 in UMLApp::qt_invoke(int, QUObject*) (this=0x81cc188,
_id=77, _o=0xbfffe260)
      at uml.moc.cpp:212
#26 0x40b128ac in QObject::activate_signal(QConnectionList*, QUObject*)
(this=0x81e7fb0,
      clist=0x81e84e8, o=0xbfffe260) at kernel/qobject.cpp:2212
#27 0x40b12743 in QObject::activate_signal(int) (this=0x81e7fb0, signal=2)
      at kernel/qobject.cpp:2186
#28 0x404f379b in KAction::activated() () from /usr/lib/libkdeui.so.4
#29 0x404e68bf in KAction::slotActivated() () from /usr/lib/libkdeui.so.4
#30 0x404f3992 in KAction::qt_invoke(int, QUObject*) () from
/usr/lib/libkdeui.so.4
#31 0x40b129cf in QObject::activate_signal(QConnectionList*, QUObject*)
(this=0x8220030,
      clist=0x8220528, o=0xbfffe370) at kernel/qobject.cpp:2232
#32 0x40b12743 in QObject::activate_signal(int) (this=0x8220030,
signal=4) at kernel/qobject.cpp:2186
#33 0x40ecc081 in QButton::clicked() (this=0x8220030)
      at .moc/debug-shared-mt/moc_qbutton.cpp:152
#34 0x40bb4324 in QButton::mouseReleaseEvent(QMouseEvent*)
(this=0x8220030, e=0xbfffe790)
      at widgets/qbutton.cpp:808
#35 0x40b546e5 in QWidget::event(QEvent*) (this=0x8220030, e=0xbfffe790)
      at kernel/qwidget.cpp:4334
#36 0x40a9eedd in QApplication::internalNotify(QObject*, QEvent*)
(this=0xbfffebd0,
      receiver=0x8220030, e=0xbfffe790) at kernel/qapplication.cpp:2350
#37 0x40a9e559 in QApplication::notify(QObject*, QEvent*) (this=0xbfffebd0,
      receiver=0x8220030, e=0xbfffe790) at kernel/qapplication.cpp:2159
#38 0x406f39c6 in KApplication::notify(QObject*, QEvent*) () from
/usr/lib/libkdecore.so.4
#39 0x40a37854 in QApplication::sendSpontaneousEvent(QObject*, QEvent*)
(receiver=0x8220030,
      event=0xbfffe790) at kernel/qapplication.h:481
#40 0x40a2feb8 in QETWidget::translateMouseEvent(_XEvent const*)
(this=0x8220030,
      event=0xbfffea70) at kernel/qapplication_x11.cpp:4217
#41 0x40a2d968 in QApplication::x11ProcessEvent(_XEvent*)
(this=0xbfffebd0, event=0xbfffea70)
      at kernel/qapplication_x11.cpp:3395
#42 0x40a484bd in QEventLoop::processEvents(unsigned) (this=0x81b1868,
flags=4)
      at kernel/qeventloop_x11.cpp:169
#43 0x40ab6949 in QEventLoop::enterLoop() (this=0x81b1868) at
kernel/qeventloop.cpp:191
#44 0x40ab6862 in QEventLoop::exec() (this=0x81b1868) at
kernel/qeventloop.cpp:138
#45 0x40a9f09b in QApplication::exec() (this=0xbfffebd0) at
kernel/qapplication.cpp:2471
#46 0x080afc9e in main (argc=1088142458, argv=0x40dbbc7a) at main.cpp:83
#47 0x420158d4 in __libc_start_main () from /lib/i686/libc.so.6

================================================
second crash was

92              QString diagram(i18n("kde-uml-Diagram"));
93              for(int i=0;i<listCount;i++) {
94                      if(m_pSelectLB -> isSelected(i)) {
95**                              UMLView *view = (UMLView *)m_pDoc ->
findView(m_nIdList[i]);
96                              QString sCount = QString("%1").arg(count);
97                              QString sID = QString("%1").arg(view ->
getID());
98                              opts.insert(diagram + sCount, sID);
99                              count++;

with m_pDoc set to an invalid address.




-- 
Joe VanAndel  	
National Center for Atmospheric Research
http://www.atd.ucar.edu/~vanandel/
Internet: vanandel at ucar dot edu






More information about the umbrello-devel mailing list