[Digikam-devel] [CRASH] writing a png crashs digikam-SVN

Thorsten Schnebeck thorsten.schnebeck at gmx.net
Fri Dec 22 11:07:54 GMT 2006


On Friday, December 15, 2006 03:51:59 PM Gilles Caulier wrote:
> On Friday 15 December 2006 13:36, Thorsten Schnebeck wrote:
> > On Friday, December 15, 2006 07:48:03 AM Gilles Caulier wrote:
> > > Not reproductible here. I use every day PNG file format to save my
> > > photo. No crash here...
> > >
> > > Your report sound like a problem with your HDD free space/ or something
> > > is broken in your KDE installation ?
> > >
> > > > kio (KIOJob): stat file:///home/schnebeck/EOS/einTest/IMG_4876.png
> > > > kio (KIOJob): error 11 /home/schnebeck/EOS/einTest/IMG_4876.png
> > >
> > > Why KIOJob return an error just before than digiKam start the PNG stuff
> > > ?
> > >
> > > Gilles
> >
> > Hi Gilles,
> >
> > no, I loaded the same image into KolourPaint that nearly have the same
> > "save as"-dialog and there it no problem to save to png. As a non-KDE
> > program GIMP has also no problems.
> > There is 12 GB left on partition, should be enough ;-)
> > Although no room on a device should never crash an already running
> > application.
> >
> > So I tried to recompile some of the involved packages to get a BT and
> > here it is:
> >
> > Program received signal SIGSEGV, Segmentation fault.
> > [Switching to Thread -1250223200 (LWP 12511)]
> > 0xb633a819 in adler32 () from /lib/libz.so.1
> > (gdb) bt
> > #0  0xb633a819 in adler32 () from /lib/libz.so.1
> > #1  0xb633d3c3 in deflateCopy () from /lib/libz.so.1
> > #2  0xb633e4fc in deflateParams () from /lib/libz.so.1
> > #3  0xb633d6c7 in deflate () from /lib/libz.so.1
> > #4  0xb64ab391 in png_save_uint_16 () from /usr/lib/libpng12.so.0
> > #5  0xb64ac498 in png_write_chunk_start () from /usr/lib/libpng12.so.0
> > #6  0xb64b2f5a in png_write_info_before_PLTE () from
> > /usr/lib/libpng12.so.0 #7  0xb64b2fbc in png_write_info () from
> > /usr/lib/libpng12.so.0
> > #8  0xb7ea86d3 in Digikam::PNGLoader::save (this=0xb57b136c,
> > filePath=@0x8519bc8,
> >     observer=0x8519bc0) at pngloader.cpp:691
> > #9  0xb7ebea99 in Digikam::DImg::save (this=0x8519bc4,
> > filePath=@0x8519bc8, format=@0x8519bcc,
> >     observer=0x8519bc0) at dimg.cpp:397
> > #10 0xb7e3c036 in Digikam::SavingTask::execute (this=0x8519bb8) at
> > loadsavetask.cpp:395
> > #11 0xb7e399fd in Digikam::LoadSaveThread::run (this=0x84cd550) at
> > loadsavethread.cpp:172
> > #12 0xb6946853 in QThreadInstance::start () from
> > /usr/qt/3/lib/libqt-mt.so.3 #13 0xb6461294 in start_thread () from
> > /lib/libpthread.so.0
> > #14 0xb620597e in clone () from /lib/libc.so.6
> >
> > (This is another computer, here is libpng12. On the other system it was
> > libpng13)
> >
> > Strange that a save command enters a loader code. Maybe that libpng does
> > not want to write a illegal png format to disk?
> > To make it clear: there is no problem to write to jpg, tiff, bmp etc.
> > When using jpeg2000 I get an error message but png results in a longer
> > freeze and then a crash.
> >
> > But its also strange that no-one else seems to trigger such a generic
> > problem.
> >
> > Bye
> >
> >   Thorsten
>
> Look like the BT sound a crash in libpng using libz (used to compress image
> data). I suspect a problem with a shared library in your system. Check it.

As the problem still exists - and still in digiKam only I collect new infos.

When I interrupt the session before digikam crashs I have this threading info:

Program received signal SIGINT, Interrupt.
[Switching to Thread -1245165904 (LWP 25514)]
0xffffe410 in __kernel_vsyscall ()
(gdb) info threads
  4 Thread -1255158880 (LWP 25528)  0xb60d741d in png_save_uint_16 () 
from /usr/lib/libpng12.so.0
  3 Thread -1255158880 (LWP 25528)  0xb60d741d in png_save_uint_16 () 
from /usr/lib/libpng12.so.0
* 1 Thread -1245165904 (LWP 25514)  0xffffe410 in __kernel_vsyscall ()

For what are the two threads necessary? Is libpng in this case threadsafe?

Full info:

(gdb) thread 4
[Switching to thread 4 (Thread -1255158880 (LWP 25528))]#0  0xb60d741d in 
png_save_uint_16 () from /usr/lib/libpng12.so.0
(gdb) bt
#0  0xb60d741d in png_save_uint_16 () from /usr/lib/libpng12.so.0
#1  0xb60d8498 in png_write_chunk_start () from /usr/lib/libpng12.so.0
#2  0xb60def5a in png_write_info_before_PLTE () from /usr/lib/libpng12.so.0
#3  0xb60defbc in png_write_info () from /usr/lib/libpng12.so.0
#4  0xb7e82623 in Digikam::PNGLoader::save (this=0xb52fc36c, 
filePath=@0x85a0c50, observer=0x85a0c48) at pngloader.cpp:691
#5  0xb7e988b9 in Digikam::DImg::save (this=0x85a0c4c, filePath=@0x85a0c50, 
format=@0x85a0c54, observer=0x85a0c48) at dimg.cpp:412
#6  0xb7e136c6 in Digikam::SavingTask::execute (this=0x85a0c40) at 
loadsavetask.cpp:395
#7  0xb7e1108d in Digikam::LoadSaveThread::run (this=0x854aa30) at 
loadsavethread.cpp:172
#8  0xb6572853 in QThreadInstance::start () from /usr/qt/3/lib/libqt-mt.so.3
#9  0xb608e294 in start_thread () from /lib/libpthread.so.0
#10 0xb5d5097e in clone () from /lib/libc.so.6


(gdb) thread 3
[Switching to thread 3 (Thread -1255158880 (LWP 25528))]#0  0xb60d741d in 
png_save_uint_16 () from /usr/lib/libpng12.so.0
(gdb) bt
#0  0xb60d741d in png_save_uint_16 () from /usr/lib/libpng12.so.0
#1  0xb60d8498 in png_write_chunk_start () from /usr/lib/libpng12.so.0
#2  0xb60def5a in png_write_info_before_PLTE () from /usr/lib/libpng12.so.0
#3  0xb60defbc in png_write_info () from /usr/lib/libpng12.so.0
#4  0xb7e82623 in Digikam::PNGLoader::save (this=0xb52fc36c, 
filePath=@0x85a0c50, observer=0x85a0c48) at pngloader.cpp:691
#5  0xb7e988b9 in Digikam::DImg::save (this=0x85a0c4c, filePath=@0x85a0c50, 
format=@0x85a0c54, observer=0x85a0c48) at dimg.cpp:412
#6  0xb7e136c6 in Digikam::SavingTask::execute (this=0x85a0c40) at 
loadsavetask.cpp:395
#7  0xb7e1108d in Digikam::LoadSaveThread::run (this=0x854aa30) at 
loadsavethread.cpp:172
#8  0xb6572853 in QThreadInstance::start () from /usr/qt/3/lib/libqt-mt.so.3
#9  0xb608e294 in start_thread () from /lib/libpthread.so.0
#10 0xb5d5097e in clone () from /lib/libc.so.6


(gdb) thread 1
[Switching to thread 1 (Thread -1245165904 (LWP 25514))]#0  0xb65d9b6f in 
QObject::receivers () from /usr/qt/3/lib/libqt-mt.so.3
(gdb) bt
#0  0xb65d9b6f in QObject::receivers () from /usr/qt/3/lib/libqt-mt.so.3
#1  0xb6e2fd2e in KToolBar::highlighted (this=0x86137d0, t0=-26, t1=true) at 
ktoolbar.moc:313
#2  0xb6e30057 in KToolBar::qt_emit (this=0x86137d0, _id=10, _o=0xbf80f6a0) at 
ktoolbar.moc:380
#3  0xb65d8e6b in QObject::activate_signal () from /usr/qt/3/lib/libqt-mt.so.3
#4  0xb6efbca4 in KToolBarButton::highlighted (this=0x862eb58, t0=-26, 
t1=true) at ktoolbarbutton.moc:192
#5  0xb6efc237 in KToolBarButton::enterEvent (this=0x862eb58) at 
ktoolbarbutton.cpp:403
#6  0xb6611ca9 in QWidget::event () from /usr/qt/3/lib/libqt-mt.so.3
#7  0xb6efe54e in KToolBarButton::event (this=0xbf80f9f4, e=0x862eb58) at 
ktoolbarbutton.cpp:651
#8  0xb65799f7 in QApplication::internalNotify () 
from /usr/qt/3/lib/libqt-mt.so.3
#9  0xb657a5e9 in QApplication::notify () from /usr/qt/3/lib/libqt-mt.so.3
#10 0xb6baed1b in KApplication::notify (this=0xbf80fd84, receiver=0x862eb58, 
event=0xbf80f9f4) at kapplication.cpp:550
#11 0xb657baed in qt_dispatchEnterLeave () from /usr/qt/3/lib/libqt-mt.so.3
#12 0xb6519824 in QApplication::x11ProcessEvent () 
from /usr/qt/3/lib/libqt-mt.so.3
#13 0xb65295e1 in QEventLoop::processEvents () 
from /usr/qt/3/lib/libqt-mt.so.3
#14 0xb6590651 in QEventLoop::enterLoop () from /usr/qt/3/lib/libqt-mt.so.3
#15 0xb65904d6 in QEventLoop::exec () from /usr/qt/3/lib/libqt-mt.so.3
#16 0xb657948f in QApplication::exec () from /usr/qt/3/lib/libqt-mt.so.3
#17 0x0804a987 in main (argc=1, argv=0xbf80ff94) at main.cpp:269

Bye

  Thorsten





More information about the Digikam-devel mailing list