[Kde-imaging] [Bug 166424] Crash when editing Caption with Digikam4 SVN

Gilles Caulier caulier.gilles at gmail.com
Wed Jul 30 16:49:05 CEST 2008


------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
         
http://bugs.kde.org/show_bug.cgi?id=166424         




------- Additional Comments From caulier.gilles gmail com  2008-07-30 16:49 -------
Andreas,

With commit #839677 digiKam and Showfoto now initialize Adobe XMP SDK at startup.

Damned, now digiKAm crash very quickly when an image is open in editor:

gdb /opt/kde4/bin/digikam --interpreter=mi2 -quiet
Using host libthread_db library "/lib/i686/libthread_db.so.1".
Exited normally(gdb) quitgdb /opt/kde4/bin/digikam --interpreter=mi2 -quiet
Using host libthread_db library "/lib/i686/libthread_db.so.1".
Quit
(gdb) quitquit
The program is running.  Exit anyway? (y or n) [answered Y; input not from terminal]
(gdb) Process exited
gdb /opt/kde4/bin/digikam --interpreter=mi2 -quiet
Using host libthread_db library "/lib/i686/libthread_db.so.1".
(gdb) bt
bt
#0  0xb51abfe7 in std::_Rb_tree<std::string, std::pair<std::string const, Exiv2::XmpNsInfo>, std::_Select1st<std::pair<std::string const, Exiv2::XmpNsInfo> >, std::less<std::string>, std::allocator<std::pair<std::string const, Exiv2::XmpNsInfo> > >::_M_insert_unique () from /usr/lib/libexiv2.so.4
#1  0xb51a9275 in Exiv2::XmpProperties::registerNs () from /usr/lib/libexiv2.so.4
#2  0xb5cf774d in KExiv2Priv (this=0xb1bb7a20) at /home/gilles/Documents/data/devel/SVN/trunk/KDE/kdegraphics/libs/libkexiv2/libkexiv2/kexiv2private.cpp:43
#3  0xb5cf378b in KExiv2 (this=0xbfee602c) at /home/gilles/Documents/data/devel/SVN/trunk/KDE/kdegraphics/libs/libkexiv2/libkexiv2/kexiv2.cpp:39
#4  0xb6b3adc5 in DMetadata (this=0xbfee602c) at /mnt/data/devel/SVN/trunk/graphics/digikam/libs/dmetadata/dmetadata.cpp:55
#5  0xb6c28178 in Digikam::ExifWidget::loadFromURL (this=0xb198cc58, url= 0xbfee60f8) at /mnt/data/devel/SVN/trunk/graphics/digikam/libs/widgets/metadata/exifwidget.cpp:113
#6  0xb6c55a55 in Digikam::ImagePropertiesMetaDataTab::setCurrentURL (this=0xb198afd0, url= 0xbfee60f8) at /mnt/data/devel/SVN/trunk/graphics/digikam/libs/imageproperties/imagepropertiesmetadatatab.cpp:149
#7  0xb6c4a1dc in Digikam::ImagePropertiesSideBar::slotNoCurrentItem (this=0xb1956438) at /mnt/data/devel/SVN/trunk/graphics/digikam/libs/imageproperties/imagepropertiessidebar.cpp:112
#8  0x080b5fa0 in Digikam::ImagePropertiesSideBarDB::slotNoCurrentItem (this=0xb1956438) at /mnt/data/devel/SVN/trunk/graphics/digikam/libs/imageproperties/imagepropertiessidebardb.cpp:180
#9  0x080b6c10 in Digikam::ImagePropertiesSideBarDB::qt_metacall (this=0xb1956438, _c=QMetaObject::InvokeMetaMethod, _id=13, _a=0xbfee61f0) at /mnt/data/devel/SVN/trunk/graphics/digikam/digikam/imagepropertiessidebardb.moc:109
#10 0xb7f56447 in QMetaObject::activate () from /usr/lib/qt4/lib/libQtCore.so.4
#11 0xb7f56fb5 in QMetaObject::activate () from /usr/lib/qt4/lib/libQtCore.so.4
#12 0xb6ca3e63 in Digikam::EditorWindow::signalNoCurrentItem (this=0xaad02588) at /mnt/data/devel/SVN/trunk/graphics/digikam/digikam/editorwindow.moc:221
#13 0xb6ca3fae in Digikam::EditorWindow::slotLoadingStarted (this=0xaad02588) at /mnt/data/devel/SVN/trunk/graphics/digikam/utilities/imageeditor/editor/editorwindow.cpp:1244
#14 0xb6ca4779 in Digikam::EditorWindow::qt_metacall (this=0xaad02588, _c=QMetaObject::InvokeMetaMethod, _id=17, _a=0xbfee6bbc) at /mnt/data/devel/SVN/trunk/graphics/digikam/digikam/editorwindow.moc:169
#15 0x080a6a2a in Digikam::ImageWindow::qt_metacall (this=0xaad02588, _c=QMetaObject::InvokeMetaMethod, _id=60, _a=0xbfee6bbc) at /mnt/data/devel/SVN/trunk/graphics/digikam/digikam/imagewindow.moc:102
#16 0xb7f56447 in QMetaObject::activate () from /usr/lib/qt4/lib/libQtCore.so.4
#17 0xb7f56fb5 in QMetaObject::activate () from /usr/lib/qt4/lib/libQtCore.so.4
#18 0xb6c88e1c in Digikam::Canvas::signalLoadingStarted (this=0xaad01e68, _t1= 0xbfee6c08) at /mnt/data/devel/SVN/trunk/graphics/digikam/digikam/canvas.moc:251
#19 0xb6c89a38 in Digikam::Canvas::load (this=0xaad01e68, filename= 0xbfee6c08, IOFileSettings=0xb19b1078) at /mnt/data/devel/SVN/trunk/graphics/digikam/utilities/imageeditor/canvas/canvas.cpp:252
#20 0x080a4ffa in Digikam::ImageWindow::slotLoadCurrent (this=0xaad02588) at /mnt/data/devel/SVN/trunk/graphics/digikam/utilities/imageeditor/editor/imagewindow.cpp:538
#21 0x080a6b74 in Digikam::ImageWindow::qt_metacall (this=0xaad02588, _c=QMetaObject::InvokeMetaMethod, _id=10, _a=0xbfee6cb0) at /mnt/data/devel/SVN/trunk/graphics/digikam/digikam/imagewindow.moc:117
#22 0xb7f56447 in QMetaObject::activate () from /usr/lib/qt4/lib/libQtCore.so.4
#23 0xb7f56fb5 in QMetaObject::activate () from /usr/lib/qt4/lib/libQtCore.so.4
#24 0xb7f5c1c5 in QAbstractItemModel::sort () from /usr/lib/qt4/lib/libQtCore.so.4
#25 0xb7f5c20c in QAbstractItemModel::sort () from /usr/lib/qt4/lib/libQtCore.so.4
#26 0xb7f532b5 in QObject::event () from /usr/lib/qt4/lib/libQtCore.so.4
#27 0xb6ede1c2 in QApplicationPrivate::notify_helper () from /usr/lib/qt4/lib/libQtGui.so.4
#28 0xb6ee4781 in QApplication::notify () from /usr/lib/qt4/lib/libQtGui.so.4
#29 0xb7a09281 in KApplication::notify () from /opt/kde4/lib/libkdeui.so.5
#30 0xb7f44378 in QCoreApplication::notifyInternal () from /usr/lib/qt4/lib/libQtCore.so.4
#31 0xb7f6768f in QAbstractItemModel::sort () from /usr/lib/qt4/lib/libQtCore.so.4
#32 0xb7f688b8 in QEventDispatcherUNIX::processEvents () from /usr/lib/qt4/lib/libQtCore.so.4
#33 0xb6f5a9a3 in QAbstractItemModel::sort () from /usr/lib/qt4/lib/libQtGui.so.4
#34 0xb7f437e3 in QEventLoop::processEvents () from /usr/lib/qt4/lib/libQtCore.so.4
#35 0xb7f438ea in QEventLoop::exec () from /usr/lib/qt4/lib/libQtCore.so.4
#36 0xb7f45c46 in QCoreApplication::exec () from /usr/lib/qt4/lib/libQtCore.so.4
#37 0xb6edd884 in QApplication::exec () from /usr/lib/qt4/lib/libQtGui.so.4
#38 0x08289c7b in main (argc=1, argv=0xbfee7bc4) at /mnt/data/devel/SVN/trunk/graphics/digikam/digikam/main.cpp:303
^done(gdb) quitquit
The program is running.  Exit anyway? (y or n) [answered Y; input not from terminal]

This is the code relevant from KEXiv2 private class destructor :

    // Fix memory leak if Exiv2 support XMP.
#ifdef _XMP_SUPPORT_
    Exiv2::XmpParser::terminate();
#endif // _XMP_SUPPORT_

Do you remember ? It's to fix memory leak from XMP SDK when KExiv2 instance is closed.

So i suppose than this call must be removed here and called in a wrapper method to cleanup memory at the right place in digiKam destructor

Gilles


More information about the Kde-imaging mailing list