Bug 136771

Summary: image editor crashes when using undo
Product: [Applications] digikam Reporter: Simon Oosthoek <kdebugs>
Component: ImageEditor-UndoAssignee: Digikam Developers <digikam-bugs-null>
Status: RESOLVED WORKSFORME    
Severity: crash    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In: 0.9.0
Sentry Crash Report:

Description Simon Oosthoek 2006-11-03 13:14:03 UTC
Version:           0.9.0 beta 3 (using KDE KDE 3.5.5)
Installed from:    Compiled From Sources
Compiler:          gcc (GCC) 4.1.2 20060928 (prerelease) (Ubuntu 4.1.1-13ubuntu5) 
OS:                Linux

When choosing undo after using an image plugin, the application crashes.

Using host libthread_db library "/lib/libthread_db.so.1".
[Thread debugging using libthread_db enabled]
[New Thread 47366316149312 (LWP 17228)]
[New Thread 1090525520 (LWP 17291)]
0x00002b145403fc71 in nanosleep () from /lib/libc.so.6
#0  0x00002b145403fc71 in nanosleep () from /lib/libc.so.6
#1  0x00002b145403fa94 in sleep () from /lib/libc.so.6
#2  0x00002b1450c19575 in KCrash::startDrKonqi ()
   from /usr/lib/libkdecore.so.4
#3  0x00002b1450c2db07 in KCrash::defaultCrashHandler ()
   from /usr/lib/libkdecore.so.4
#4  0x00002b1453fdb510 in killpg () from /lib/libc.so.6
#5  0x0000000000000000 in ?? ()
Comment 1 caulier.gilles 2006-11-03 13:38:42 UTC
The backtrace is uncomplete. Please comile digiKam using full debug informations (look ./configure options)

Gilles Caulier
Comment 2 Simon Oosthoek 2006-11-03 15:24:29 UTC
The backtrace with enable-debug=full doesn't seem much different:

Using host libthread_db library "/lib/libthread_db.so.1".
[Thread debugging using libthread_db enabled]
[New Thread 47285965711936 (LWP 25042)]
[New Thread 1090525520 (LWP 25058)]
0x00002b019ec19c71 in nanosleep () from /lib/libc.so.6
#0  0x00002b019ec19c71 in nanosleep () from /lib/libc.so.6
#1  0x00002b019ec19a94 in sleep () from /lib/libc.so.6
#2  0x00002b019b7f3575 in KCrash::startDrKonqi ()
   from /usr/lib/libkdecore.so.4
#3  0x00002b019b807b07 in KCrash::defaultCrashHandler ()
   from /usr/lib/libkdecore.so.4
#4  0x00002b019ebb5510 in killpg () from /lib/libc.so.6
#5  0x0000000000000000 in ?? ()

and on the konsole from which I started digikam:

digikam: UnsharpMask::End of computation !!! ... ( 15 s )
terminate called after throwing an instance of 'std::bad_alloc'
  what():  St9bad_alloc
KCrash: Application 'digikam' crashing...
Comment 3 caulier.gilles 2006-11-03 16:37:28 UTC
OK. This problem is fixed in current digiKam implementation from svn. Look this B.K.O file :

http://bugs.kde.org/show_bug.cgi?id=133026

Please can you checkout svn reprository and try again ?

Gilles Caulier
Comment 4 Simon Oosthoek 2006-11-04 00:43:00 UTC
No the svn version doesn't change it at all, I get the exact same behaviour.
again a (meaningless?) trace:

Using host libthread_db library "/lib/libthread_db.so.1".
[Thread debugging using libthread_db enabled]
[New Thread 47771045554752 (LWP 29078)]
[New Thread 1090525520 (LWP 29093)]
0x00002b728fc49c71 in nanosleep () from /lib/libc.so.6
#0  0x00002b728fc49c71 in nanosleep () from /lib/libc.so.6
#1  0x00002b728fc49a94 in sleep () from /lib/libc.so.6
#2  0x00002b728c823575 in KCrash::startDrKonqi ()
   from /usr/lib/libkdecore.so.4
#3  0x00002b728c837b07 in KCrash::defaultCrashHandler ()
   from /usr/lib/libkdecore.so.4
#4  0x00002b728fbe5510 in killpg () from /lib/libc.so.6
#5  0x0000000000000000 in ?? ()

I'm running this on kubuntu edgy on an amd64 (athlon64 3000+)
$ uname -a
Linux stamper 2.6.17-10-generic #2 SMP Fri Oct 13 15:34:39 UTC 2006 x86_64 GNU/Linux

lspci:
00:00.0 Host bridge: Silicon Integrated Systems [SiS] Unknown device 0756 (rev 02)
00:01.0 PCI bridge: Silicon Integrated Systems [SiS] PCI-to-PCI bridge
00:02.0 ISA bridge: Silicon Integrated Systems [SiS] SiS965 [MuTIOL Media IO] (rev 48)
00:02.5 IDE interface: Silicon Integrated Systems [SiS] 5513 [IDE] (rev 01)
00:02.7 Multimedia audio controller: Silicon Integrated Systems [SiS] AC'97 Sound Controller (rev a0)
00:03.0 USB Controller: Silicon Integrated Systems [SiS] USB 1.0 Controller (rev 0f)
00:03.1 USB Controller: Silicon Integrated Systems [SiS] USB 1.0 Controller (rev 0f)
00:03.2 USB Controller: Silicon Integrated Systems [SiS] USB 1.0 Controller (rev 0f)
00:03.3 USB Controller: Silicon Integrated Systems [SiS] USB 2.0 Controller
00:04.0 Ethernet controller: Silicon Integrated Systems [SiS] 190 Gigabit Ethernet Adapter
00:05.0 IDE interface: Silicon Integrated Systems [SiS] 182 SATA/RAID Controller (rev 01)
00:06.0 PCI bridge: Silicon Integrated Systems [SiS] PCI-to-PCI bridge
00:07.0 PCI bridge: Silicon Integrated Systems [SiS] PCI-to-PCI bridge
00:18.0 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] HyperTransport Technology Configuration
00:18.1 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Address Map
00:18.2 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] DRAM Controller
00:18.3 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Miscellaneous Control
01:00.0 VGA compatible controller: nVidia Corporation GeForce 6200 TurboCache(TM) (rev a1)
Comment 5 caulier.gilles 2006-12-12 09:14:11 UTC
Simon,

This crash still reproductible using digiKam & DigikamImagePlugins 0.9.0-RC2 ?

Gilles
Comment 6 Simon Oosthoek 2006-12-16 16:25:07 UTC
sorry, I'm having trouble compiling the RC2 or svn version right now...

/bin/bash ../../libtool --silent --tag=CXX --mode=link g++  -Wno-long-long -Wundef -ansi -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -g3 -fno-inline -Wformat-security -Wmissing-format-attribute -Wno-non-virtual-dtor -fno-exceptions -fno-check-new -fno-common -DQT_CLEAN_NAMESPACE -DQT_NO_ASCII_CAST -DQT_NO_STL -DQT_NO_COMPAT -DQT_NO_TRANSLATION -DQT_CLEAN_NAMESPACE    -o libdigikam.la -rpath /usr/lib -L/usr/share/qt3/lib -L/usr/lib    -R /usr/lib -R /usr/lib -R /usr/share/qt3/lib -R /usr/lib -no-undefined -Wl,--no-undefined -Wl,--allow-shlib-undefined kdateedit.lo album.lo albumdb.lo albumdb_sqlite2.lo albumiconview.lo albumicongroupitem.lo albumiconitem.lo albumitemhandler.lo albumfiletip.lo albumfolderview.lo albumhistory.lo albumlister.lo albummanager.lo albumpropsedit.lo albumsettings.lo albumthumbnailloader.lo albumwidgetstack.lo batchthumbsgenerator.lo cameradragobject.lo cameralist.lo cameratype.lo datefolderview.lo dcopiface.lo digikamapp.lo digikamfirstrun.lo digikamview.lo dio.lo dragobjects.lo firstrun.lo folderitem.lo folderview.lo iconview.lo icongroupitem.lo iconitem.lo imageattributeswatch.lo imageinfo.lo imagepreviewwidget.lo imagepreviewjob.lo kdatetimeedit.lo kdatepickerpopup.lo kipiinterface.lo monthwidget.lo pixmapmanager.lo ratingwidget.lo scanlib.lo searchadvanceddialog.lo searchfolderview.lo searchquickdialog.lo searchresultsview.lo searchresultsitem.lo searchwidgets.lo syncjob.lo tagcreatedlg.lo tagfilterview.lo tagfolderview.lo tagspopupmenu.lo upgradedb_sqlite2tosqlite3.lo dcopiface_skel.lo -lkio -lsqlite3   -lkabc -lkipi   -lkutils -L/usr/local/lib -lexiv2 -lz -lm ../../digikam/sqlite/libsqlite.la ../../digikam/libs/thumbbar/libthumbbar.la ../../digikam/libs/themeengine/libthemeengine.la ../../digikam/libs/widgets/libwidgets.la ../../digikam/libs/dialogs/libdialog.la ../../digikam/libs/jpegutils/libjpegutils.la ../../digikam/libs/imageproperties/libimagepropertiesdigikam.la ../../digikam/libs/threadimageio/libthreadimageio.la ../../digikam/utilities/cameragui/libcameragui.la ../../digikam/utilities/imageeditor/canvas/libdimgcanvas.la ../../digikam/utilities/imageeditor/editor/libdimgeditor.la ../../digikam/utilities/splashscreen/libsplashscreen.la ../../digikam/utilities/setup/libsetup.la
../../digikam/utilities/imageeditor/canvas/.libs/libdimgcanvas.a(dmetadata.o): In function `Digikam::DMetadata::clearExif()':
/home/simon/src/digikam-0.9.0-rc2/digikam/libs/dmetadata/dmetadata.cpp:85: undefined reference to `Exiv2::ExifData::clear()'
collect2: ld returned 1 exit status
make[3]: *** [libdigikam.la] Error 1
make[3]: Leaving directory `/home/simon/src/digikam-0.9.0-rc2/digikam/digikam'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/simon/src/digikam-0.9.0-rc2/digikam'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/simon/src/digikam-0.9.0-rc2'
make: *** [all] Error 2
Comment 7 caulier.gilles 2006-12-16 18:08:48 UTC
You need to update Exiv to 0.12 release...

Gilles
Comment 8 Simon Oosthoek 2006-12-16 22:40:55 UTC
I've removed the edgy 0.10 dev libs of exiv2, compiled and installed the exiv2 v0.12 from the sources. rc2 now compiles but I still get a crash on exiv2:

digikam: ImagePlugin_Core plugin loaded
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_Core
terminate called after throwing an instance of 'Exiv2::Error'
KCrash: Application 'digikam' crashing...

the backtrace wasn't worth putting here, since this is actually off topic anyway.

I guess for testing it would be helpful if an edgy repository was set up with binaries for testing digikam on kubuntu edgy ;-)
Comment 9 Simon Oosthoek 2006-12-17 13:02:05 UTC
I didn't remove the runtime library of exiv2 0.10, because ufraw of the gimp depended on that. removing the lib fixed the startup problem, obviously ;-)

rc2 seems to have fixed the problem of the bug, but I've only tested the red-eye plugin, since I haven't compiled the plugins again yet.
Comment 10 caulier.gilles 2006-12-17 13:19:59 UTC
I need more feedback before to close this file. Please try to check if the problem cannot be reproduce, especially with Exiv2 0.12

Gilles
Comment 11 Simon Oosthoek 2006-12-17 17:31:14 UTC
after a lot of fighting with the rc2 plugins, I switched back to the latest svn version, finally it compiled and installed...

I tried editing a picture with several plugins, undid the result and didn't get any crash. To me, this one seems fixed.

thanks a lot

/Simon