Bug 144799 - crash when downloading images
Summary: crash when downloading images
Status: RESOLVED NOT A BUG
Alias: None
Product: digikam
Classification: Applications
Component: Import-Gphoto2 (show other bugs)
Version: 0.8.2
Platform: Ubuntu Linux
: NOR crash
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-04-28 17:03 UTC by mgolden
Modified: 2017-08-16 06:14 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description mgolden 2007-04-28 17:03:53 UTC
Version:           0.8.2 (using KDE KDE 3.5.5)
Installed from:    Ubuntu Packages
OS:                Linux

I am using Ubuntu Edgy Eft.  I have a sipix snap.  It seems everything is fine, until I try to download the images.  It starts the download process, and after watching the little wheel spin for a brief period, it crashes.  This is absolutely repeatable.

Here is the backtrace:

(no debugging symbols found)
Using host libthread_db library "/lib/tls/i686/cmov/libthread_db.so.1".
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
[Thread debugging using libthread_db enabled]
[New Thread -1239165264 (LWP 5770)]
[New Thread -1249793120 (LWP 5788)]
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
0xffffe410 in __kernel_vsyscall ()
#0  0xffffe410 in __kernel_vsyscall ()
#1  0xb6351d1e in pthread_exit () from /lib/tls/i686/cmov/libc.so.6
#2  0xb6482fc1 in operator delete () from /usr/lib/libstdc++.so.6
#3  0xb6df3944 in QGList::take () from /usr/lib/libqt-mt.so.3
#4  0xb6a824b5 in QPtrList<TimerInfo>::take () from /usr/lib/libqt-mt.so.3
#5  0xb6a81547 in QEventLoop::activateTimers () from /usr/lib/libqt-mt.so.3
#6  0xb6a35ec5 in QEventLoop::processEvents () from /usr/lib/libqt-mt.so.3
#7  0xb6aa925e in QEventLoop::enterLoop () from /usr/lib/libqt-mt.so.3
#8  0xb6aa906e in QEventLoop::exec () from /usr/lib/libqt-mt.so.3
#9  0xb6a90731 in QApplication::exec () from /usr/lib/libqt-mt.so.3
#10 0x0804a756 in main ()
Comment 1 caulier.gilles 2007-04-28 18:52:24 UTC
This crash is not valid (backtrace is unsuitable).

Also, since digiKam 0.9.1 is available, 0.8.x serie is not maintened.

The camera gui have been very improved in digikam 0.9.x. Please update to last release and try again.

Gilles Caulier
Comment 2 mgolden 2007-04-29 00:07:32 UTC
I tried this with Feisty Fawn, which is distributed with digiKam 0.9.1, but it still crashes.  I should say that Konqueror seems to see the camera and can see picture files on it but doesn't copy them off.  Instead it says

The process for the camera://usb:001,022 protocol died unexpectedly

When I try to download in digiKam it spins for a while and crashes.  The KDE crash handler says that it's unable to create a valid backtrace.  It looks like this:

...
0xffffe410 in __kernel_vsyscall()
#0  0xffffe410 in __kernel_vsyscall()
#1  0xb5b7805e in ??  () from /lib/tls/i686/cmov/libc.so.6
#2  0xb5b078fe in ??  () from /lib/tls/i686/cmov/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)

What should I do to get a better trace?  Is there a debug flag I can turn on when invoking?
Comment 3 mgolden 2007-04-29 00:18:18 UTC
OK, I started digiKam under gdb and got a better stack trace:

*** glibc detected *** digikam: realloc(): invalid next size: 0x08950f70 ***
======= Backtrace: =========
/lib/tls/i686/cmov/libc.so.6[0xb5bd518a]
/lib/tls/i686/cmov/libc.so.6(realloc+0xfe)[0xb5bd708e]
/usr/lib/libgphoto2.so.2(gp_file_append+0x94)[0xb5dffb54]
/usr/lib/libgphoto2/2.3.0/sipix_blink2.so[0xb46416cc]
/usr/lib/libgphoto2.so.2[0xb5e03152]
/usr/lib/libgphoto2.so.2(gp_filesystem_get_file+0x44)[0xb5e03334]
/usr/lib/libgphoto2.so.2(gp_camera_file_get+0x122)[0xb5df96a2]
/usr/lib/libdigikam.so.0(_ZN7Digikam8GPCamera12downloadItemERK7QStringS3_S3_+0x10a)[0xb7ea444a]
/usr/lib/libdigikam.so.0(_ZN7Digikam12CameraThread3runEv+0x17cf)[0xb7ec950f]
/usr/lib/libqt-mt.so.3(_ZN15QThreadInstance5startEPv+0xb1)[0xb6400fd9]
/lib/tls/i686/cmov/libpthread.so.0[0xb5e9c31b]
/lib/tls/i686/cmov/libc.so.6(clone+0x5e)[0xb5c3b57e]
======= Memory map: ========
08048000-0804c000 r-xp 00000000 03:01 1338458    /usr/bin/digikam
0804c000-0804d000 rw-p 00004000 03:01 1338458    /usr/bin/digikam
0804d000-0899d000 rw-p 0804d000 00:00 0          [heap]
b3b00000-b3b21000 rw-p b3b00000 00:00 0
b3b21000-b3c00000 ---p b3b21000 00:00 0
b3c4e000-b3c53000 r-xp 00000000 03:01 865467     /usr/lib/kde3/kfile_pnm.so
b3c53000-b3c54000 rw-p 00005000 03:01 865467     /usr/lib/kde3/kfile_pnm.so
b3c54000-b3c94000 rw-p b3c54000 00:00 0
b3c94000-b3ceb000 r-xp 00000000 03:01 864976     /usr/lib/kde3/digikamimageplugin_core.so
b3ceb000-b3cef000 rw-p 00056000 03:01 864976     /usr/lib/kde3/digikamimageplugin_core.so
b3cef000-b3d37000 r-xp 00000000 03:01 865699     /usr/lib/kde3/kipiplugin_rawconverter.so
b3d37000-b3d3a000 rw-p 00047000 03:01 865699     /usr/lib/kde3/kipiplugin_rawconverter.so
b3d3a000-b3d53000 r-xp 00000000 03:01 865703     /usr/lib/kde3/kipiplugin_simpleviewer.so
b3d53000-b3d54000 rw-p 00019000 03:01 865703     /usr/lib/kde3/kipiplugin_simpleviewer.so
b3d54000-b3dca000 r-xp 00000000 03:01 865671     /usr/lib/kde3/kipiplugin_batchprocessimages.so
b3dca000-b3dcf000 rw-p 00076000 03:01 865671     /usr/lib/kde3/kipiplugin_batchprocessimages.so
b3dcf000-b3dd7000 r-xp 00000000 03:01 1339778    /usr/lib/libdrm.so.2.3.0
b3dd7000-b3dd8000 rw-p 00008000 03:01 1339778    /usr/lib/libdrm.so.2.3.0
b3dd8000-b3ddc000 r-xp 00000000 03:01 1339653    /usr/lib/libXxf86vm.so.1.0.0
b3ddc000-b3ddd000 rw-p 00003000 03:01 1339653    /usr/lib/libXxf86vm.so.1.0.0
b3ddd000-b3e3a000 r-xp 00000000 03:01 1339520    /usr/lib/libGL.so.1.2
b3e3a000-b3e3c000 rw-p 0005d000 03:01 1339520    /usr/lib/libGL.so.1.2
b3e3c000-b3e3d000 rw-p b3e3c000 00:00 0
b3e3d000-b3e89000 r-xp 00000000 03:01 1339539    /usr/lib/libImlib2.so.1.3.0
b3e89000-b3e8a000 rw-p 0004c000 03:01 1339539    /usr/lib/libImlib2.so.1.3.0
b3e8a000-b3e9e000 rw-p b3e8a000 00:00 0
b3e9e000-b3ed2000 r-xp 00000000 03:01 865705     /usr/lib/kde3/kipiplugin_slideshow.so
b3ed2000-b3ed5000 rw-p 00033000 03:01 865705     /usr/lib/kde3/kipiplugin_slideshow.so
b3ed5000-b3f24000 r-xp 00000000 03:01 1339836    /usr/lib/libgcrypt.so.11.2.2
b3f24000-b3f26000 rw-p 0004e000 03:01 1339836    /usr/lib/libgcrypt.so.11.2.2
b3f26000-b403d000 r-xp 00000000 03:01 1340567    /usr/lib/libxml2.so.2.6.27
b403d000-b4043000 rw-p 00116000 03:01 1340567    /usr/lib/libxml2.so.2.6.27
b4043000-b4076000 r-xp 00000000 03:01 1340571    /usr/lib/libxslt.so.1.1.20
b4076000-b4077000 rw-p 00032000 03:01 1340571    /usr/lib/libxslt.so.1.1.20
b4077000-b4087000 r-xp 00000000 03:01 1339793    /usr/lib/libexslt.so.0.8.13
b4087000-b4088000 rw-p 0000f000 03:01 1339793    /usr/lib/libexslt.so.0.8.13
b408a000-b4090000 r-xp 00000000 03:01 897726     /lib/libusb-0.1.so.4.4.4
b4090000-b4092000 rw-p 00005000 03:01 897726     /lib/libusb-0.1.so.4.4.4
b4092000-b4096000 r-xp 00000000 03:01 1388024    /usr/lib/libgphoto2_port/0.7.0/usb.so
b4096000-b4097000 rw-p 00003000 03:01 1388024    /usr/lib/libgphoto2_port/0.7.0/usb.so
b4097000-b40b8000 r-xp 00000000 03:01 865685     /usr/lib/kde3/kipiplugin_htmlexport.so
b40b8000-b40ba000 rw-p 00020000 03:01 865685     /usr/lib/kde3/kipiplugin_htmlexport.so
b40ba000-b40ea000 r-xp
Program received signal SIGABRT, Aborted.
[Switching to Thread -1257129072 (LWP 8869)]
0xffffe410 in __kernel_vsyscall ()
Comment 4 caulier.gilles 2007-04-29 08:51:22 UTC
The backtrace is better but not optimum. There is no debug info available.

You need to compile digiKam using ./configure --enable-debug=full.

Also, the crash appear in libgphoto2. Witch version you use ?

And witch camera you use ? Witch protocol is used to download files from camera ?

Gilles Caulier
Comment 5 mgolden 2007-04-29 09:29:57 UTC
I have an old sipix snap.  I am using whichever version of libgphoto2 is part of ubuntu feisty fawn - I assume it is the most recent one, but how can I tell?

I have to install the compiler and everything to do the recompile.  I will do this and get back to you.
Comment 6 Arnd Baecker 2007-06-06 16:51:56 UTC
Any news on this crash? Maybe you could try 0.9.2beta3 to see if 
the problem still persists?
Comment 7 mgolden 2007-06-06 16:55:06 UTC
In order to actually do the recompile of the latest version, I had to 
upgrade my machine from Edgy to Feisty.  This I finally did this weekend 
so I will be doing the re-test within the next few days.

On Wed, 6 Jun 2007, Arnd Baecker wrote:

[bugs.kde.org quoted mail]
Comment 8 mgolden 2007-06-10 01:29:48 UTC
OK, I am building on Ubuntu Gutsy alpha 1.  I did this in order to get a late version of digiKam (0.9.2-beta2).

In order to build, configure told me I was missing some libraries, so I had to install from the repositories libsqlite3-dev, libgphoto-2-dev, libkipi0-dev, libkexiv2-dev, and libkdcraw-dev.  Then, ./configure worked, but when I tried make I got yet another error: it wanted libexiv.  So I got libexiv2-dev from the repositories as well.  Once more I did a ./configure --enable-debug=full and then make, and it worked.  I could run ./digikam/digikam/digikam and, as before, when I tried to download the photos of the Sipix Snap it crashed.  The first listing below is what it said on the screen as it was running (for the second time), and below that is the backtrace reported by KCrash (which, as you can see, is useless).  I'll try again to run it under gdb.

mgolden@vincent:~/digikam-0.9.2~beta2$ ./digikam/digikam/digikam
X Error: BadDevice, invalid or uninitialized input device 169
  Major opcode:  146
  Minor opcode:  3
  Resource id:  0x0
Failed to open device
X Error: BadDevice, invalid or uninitialized input device 169
  Major opcode:  146
  Minor opcode:  3
  Resource id:  0x0
Failed to open device
digikam: ScanLib: Finding non-existing Albums: 8 ms
digikam: ScanLib: Finding items not in the database or disk: 513 ms
digikam: ScanLib: Updating items without date: 0 ms
Found dcraw version: 8.60
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_Core
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_RainDrop
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_InPainting
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_Infrared
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_Texture
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_Border
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_OilPaint
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_InsertText
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_Emboss
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_NoiseReduction
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_HotPixels
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_AdjustLevels
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_ShearTool
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_DistortionFX
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_LensDistortion
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_FilmGrain
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_ColorFx
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_Restoration
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_SuperImpose
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_WhiteBalance
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_BlurFX
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_AntiVignetting
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_AdjustCurves
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_FreeRotation
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_Perspective
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_ChannelMixer
digikam: ImagePluginLoader: Loaded plugin ImagePlugin_Charcoal
digikam: Failed to get camera item!
digikam: Libgphoto2 error: Unsupported operation (-6)
File 'image0000.pnm' is not readable.
digikam: Failed to get camera item!
digikam: Libgphoto2 error: Unsupported operation (-6)
KCrash: Application 'lt-digikam' crashing...


This backtrace appears to be of no use.
This is probably because your packages are built in a way which prevents creation of proper backtraces, or the stack frame was seriously corrupted in the crash.

Using host libthread_db library "/lib/tls/i686/cmov/libthread_db.so.1".
[Thread debugging using libthread_db enabled]
[New Thread -1248523632 (LWP 5892)]
[New Thread -1258988656 (LWP 5972)]
0xffffe410 in ?? ()
#0  0xffffe410 in ?? ()
#1  0xbfc4a638 in ?? ()
#2  0x00000002 in ?? ()
#3  0x00000000 in ?? ()
Comment 9 mgolden 2007-06-10 02:58:16 UTC
I found that I could run .libs/digikam under gdb.  Here's the backtrace I got:

(gdb) bt
#0  0xb5b07689 in ?? () from /lib/tls/i686/cmov/libc.so.6
#1  0xb398f442 in ?? () from /usr/lib/libgphoto2/2.3.1/sipix_blink2.so
#2  0x00000000 in ?? ()

I guess that's not too helpful.  I will see if I can rebuild gphoto2 from source as well!
Comment 10 mgolden 2007-06-10 04:49:35 UTC
I recompiled libgphoto2 and I am still getting the same backtrace.  Any other ideas?
Comment 11 Arnd Baecker 2007-06-12 09:52:17 UTC
Thanks a lot for all your debugging!
It indeed does look like a problem with gphoto2.
So `gphoto2 --version` will give the 2.3.1, right?
What does the output of `gphoto2 --auto-detect` give?
What does `gphoto2 -l` (to list folders) and `gphoto2 -L` (to list
files in a folder, maybe with an additional --folder=name_of_a_folder) give?
Then you could try to fetch the specific file (via --get-file, 
see `man gphoto2`).
Maybe this does help to find out what is going wrong.
Comment 12 mgolden 2007-06-12 15:30:43 UTC
I actually didn't build gphoto2, just libgphoto2.  It was 2.3.1.  I 
believe I know why I can't get a backtrace: these routines are all 
declared static and are accessed via a jump table.  I think this means 
that they don't have external symbols and therefore gdb can't find them.

I am not 100% sure that the SiPix Snap is supposed to be supported, but in 
any case I don't think it should crash.
Comment 13 Arnd Baecker 2007-06-12 16:05:00 UTC
But is it gphoto crashing? Or does it give any error messages
for the commands given in #11?
Comment 14 Marcus Meissner 2007-06-12 16:28:41 UTC
The backtrace definitely shows a memory corruption in the SiPix Blink2 driver
in libgphoto2.

(unfortunately my blink2 is broken, so this makes it difficult to reproduce)
Comment 15 Arnd Baecker 2007-06-12 18:14:00 UTC
If this is caused by libgphoto2 (and not reproducible anymore due to hardware
failure), I'd suggest to close this bug ...
Comment 16 caulier.gilles 2007-06-12 18:16:50 UTC
Agree to close it. The report must be moved to Gphoto2 bugzilla...

Gilles Caulier
Comment 17 mgolden 2007-06-12 18:17:01 UTC
It is caused by libgphoto2, and I can reproduce it every time I try to 
download from the camera.  I will spend a bit more time looking at it 
later if I can - certainly within the next few days.
Comment 18 mgolden 2007-06-12 18:39:51 UTC
If you do close it, please let me know where the gphoto2 bugzilla is and 
let me know where I can file whatever I find.
Comment 19 Arnd Baecker 2007-06-12 18:45:48 UTC
http://www.gphoto.org/feedback/

Closing this bug now (marking as invalid for digikam, 
because it is a gphoto2 bug)
Comment 20 caulier.gilles 2007-06-12 18:54:12 UTC
Arnd,

Just look like the link to Gphoto2 bugzilla is availalble on contrib digiKam web project page :

http://www.digikam.org/?q=contrib

Gilles