Bug 210206 - digikam segfaults when importing from compactflash
Summary: digikam segfaults when importing from compactflash
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Import-PostProcessing (show other bugs)
Version: 1.0.0
Platform: Compiled Sources Linux
: NOR crash
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-10-11 16:57 UTC by Salvatore Brigaglia
Modified: 2022-01-26 11:42 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 7.6.0


Attachments
the backtrace from kcrash (15.78 KB, application/octet-stream)
2009-10-11 17:02 UTC, Salvatore Brigaglia
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Salvatore Brigaglia 2009-10-11 16:57:10 UTC
Version:           1.0.0 svn r1033894 (using Devel)
OS:                Linux
Installed from:    Compiled sources

I am experiencig a reproducible segmentation fault when trying to import pictures directly from the compact flash of my camera. Importing them directly from the camera works as usual but digiKam crashes if i try to import the very same pictures using the CF trough a Trust USB2 card reader.
Comment 1 Salvatore Brigaglia 2009-10-11 17:02:10 UTC
Created attachment 37513 [details]
the backtrace from kcrash
Comment 2 caulier.gilles 2009-10-11 18:03:25 UTC
Crash appears in Exiv2 library when metadata are read. 

Which version of Exiv2 you use ? Go to Help/components Info for details.

Can you identify which file is relevant ?

Gilles Caulier
Comment 3 Salvatore Brigaglia 2009-10-11 18:37:23 UTC
(In reply to comment #2)
> Crash appears in Exiv2 library when metadata are read. 
> 
> Which version of Exiv2 you use ? Go to Help/components Info for details.
> 
> Can you identify which file is relevant ?
> 
> Gilles Caulier

Libexiv2 is 0.18.2
The CF contains a lot of images, crash appears when no thumbnails are created yet. I'll start digikam from gdb and have a look if i can fint wich image is giving us trouble.
Comment 4 Salvatore Brigaglia 2009-10-11 20:06:37 UTC
(In reply to comment #3)

> The CF contains a lot of images, crash appears when no thumbnails are created
> yet. I'll start digikam from gdb and have a look if i can fint wich image is
> giving us trouble.

I'm testing exiv2 directly on images. No problems here. I'm doing
#exiv2 * 
in the images folder, after that i do

#exiv2 -e t *

But exiv2 does not crashes. Can i try something else?
Comment 5 Salvatore Brigaglia 2009-10-11 21:09:50 UTC
Gilles,

I tried to copy all images from the CF into a local folder and used the "import images" from import menu. All thumbnails are generated correcty and no crash. Tried again to import from the CF and the segfault happened again so it is not a problem on one of the image but is a matter of from where the image in downloaded.

I'm really disappointed...
Comment 6 Marcel Wiesweg 2009-10-12 15:53:01 UTC
SVN commit 1034346 by mwiesweg:

Do not access citem after it has been removed.
Additionally, I dont see the indication for dynamic_cast here. Use static_cast.

CCBUG: 210206
CCBUG: 204967

 M  +6 -5      cameraui.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1034346
Comment 7 Marcel Wiesweg 2009-10-12 15:54:21 UTC
Salvtore, can you test the fix in SVN?
Comment 8 Salvatore Brigaglia 2009-10-12 17:18:12 UTC
(In reply to comment #7)
> Salvtore, can you test the fix in SVN?

Fixed! 

But now it is creating thumbnails without showing it at the same time. Not one by one. This causes the effect that digiKam seems frozen. After a while (not so much) all thumbnails are shown at the same time, but this is another bug...
Comment 9 Salvatore Brigaglia 2009-10-12 17:21:02 UTC
(In reply to comment #8)

> But now it is creating thumbnails without showing it at the same time.

I meant without showing them one by one, but showing them at the same time once loaded...