Bug 314117 - Segmentation fault on launching import from scanner
Summary: Segmentation fault on launching import from scanner
Status: RESOLVED FIXED
Alias: None
Product: libksane
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: unspecified
Platform: Debian stable Linux
: NOR crash
Target Milestone: ---
Assignee: Kåre Särs
URL:
Keywords:
: 268283 (view as bug list)
Depends on:
Blocks:
 
Reported: 2013-01-30 09:10 UTC by Andrew Goodbody
Modified: 2013-02-11 20:24 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In: 3.0.0


Attachments
New crash information added by DrKonqi (10.60 KB, text/plain)
2013-01-30 09:23 UTC, Andrew Goodbody
Details
New crash information added by DrKonqi (10.60 KB, text/plain)
2013-01-30 09:23 UTC, Andrew Goodbody
Details
New crash information added by DrKonqi (10.60 KB, text/plain)
2013-01-30 09:23 UTC, Andrew Goodbody
Details
New crash information added by DrKonqi (8.05 KB, text/plain)
2013-01-30 11:57 UTC, Andrew Goodbody
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Andrew Goodbody 2013-01-30 09:10:08 UTC
Application: digikam (2.9.0)
KDE Platform Version: 4.8.4 (4.8.4)
Qt Version: 4.8.2
Operating System: Linux 3.2.0-4-amd64 x86_64
Distribution: Debian GNU/Linux 7.0 (wheezy)

-- Information about the crash:
- What I was doing when the application crashed:

I had used import from scanner once and was launching it for a 2nd time when the segfault occurred.

-- Backtrace:
Application: digiKam (digikam), signal: Segmentation fault
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[Current thread is 1 (Thread 0x7fe8191b7a00 (LWP 14352))]

Thread 5 (Thread 0x7fe7f0975700 (LWP 14355)):
#0  pthread_cond_wait@@GLIBC_2.3.2 () at ../nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:162
#1  0x00007fe813f3a20b in wait (time=18446744073709551615, this=0x2a7c190) at thread/qwaitcondition_unix.cpp:86
#2  QWaitCondition::wait (this=<optimized out>, mutex=0x2a864c8, time=18446744073709551615) at thread/qwaitcondition_unix.cpp:158
#3  0x00000000005cef98 in Digikam::ScanController::run (this=0x293ba10) at /home/ag/src/digikam-2.9.0/core/digikam/database/scancontroller.cpp:698
#4  0x00007fe813f39d0b in QThreadPrivate::start (arg=0x293ba10) at thread/qthread_unix.cpp:307
#5  0x00007fe812bbdb50 in start_thread (arg=<optimized out>) at pthread_create.c:304
#6  0x00007fe8131eca7d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112
#7  0x0000000000000000 in ?? ()

Thread 4 (Thread 0x7fe7f0174700 (LWP 14356)):
#0  0x00007fe8131e1e33 in *__GI___poll (fds=<optimized out>, nfds=<optimized out>, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:87
#1  0x00007fe80c5ac624 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007fe80c5ac744 in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#3  0x00007fe814063296 in QEventDispatcherGlib::processEvents (this=0x2a86450, flags=...) at kernel/qeventdispatcher_glib.cpp:426
#4  0x00007fe8140338af in QEventLoop::processEvents (this=this@entry=0x7fe7f0173b70, flags=...) at kernel/qeventloop.cpp:149
#5  0x00007fe814033b38 in QEventLoop::exec (this=0x7fe7f0173b70, flags=...) at kernel/qeventloop.cpp:204
#6  0x00007fe813f36d70 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:501
#7  0x00007fe8140141bf in QInotifyFileSystemWatcherEngine::run (this=0x293a860) at io/qfilesystemwatcher_inotify.cpp:248
#8  0x00007fe813f39d0b in QThreadPrivate::start (arg=0x293a860) at thread/qthread_unix.cpp:307
#9  0x00007fe812bbdb50 in start_thread (arg=<optimized out>) at pthread_create.c:304
#10 0x00007fe8131eca7d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112
#11 0x0000000000000000 in ?? ()

Thread 3 (Thread 0x7fe7ef973700 (LWP 14367)):
#0  pthread_cond_wait@@GLIBC_2.3.2 () at ../nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:162
#1  0x00007fe813f3a20b in wait (time=18446744073709551615, this=0x2ca3340) at thread/qwaitcondition_unix.cpp:86
#2  QWaitCondition::wait (this=<optimized out>, mutex=0x2cc3598, time=18446744073709551615) at thread/qwaitcondition_unix.cpp:158
#3  0x00007fe816c9c239 in Digikam::ParkingThread::run (this=0x2cc3580) at /home/ag/src/digikam-2.9.0/core/libs/threads/threadmanager.cpp:119
#4  0x00007fe813f39d0b in QThreadPrivate::start (arg=0x2cc3580) at thread/qthread_unix.cpp:307
#5  0x00007fe812bbdb50 in start_thread (arg=<optimized out>) at pthread_create.c:304
#6  0x00007fe8131eca7d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112
#7  0x0000000000000000 in ?? ()

Thread 2 (Thread 0x7fe7d8c58700 (LWP 14511)):
#0  0x00007fe8131e1e33 in *__GI___poll (fds=<optimized out>, nfds=<optimized out>, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:87
#1  0x00007fe80c5ac624 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#2  0x00007fe80c5ac744 in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#3  0x00007fe814063296 in QEventDispatcherGlib::processEvents (this=0x56efce0, flags=...) at kernel/qeventdispatcher_glib.cpp:426
#4  0x00007fe8140338af in QEventLoop::processEvents (this=this@entry=0x7fe7d8c57b40, flags=...) at kernel/qeventloop.cpp:149
#5  0x00007fe814033b38 in QEventLoop::exec (this=0x7fe7d8c57b40, flags=...) at kernel/qeventloop.cpp:204
#6  0x00007fe816c9b89b in Digikam::WorkerObjectRunnable::run (this=0x47695b0) at /home/ag/src/digikam-2.9.0/core/libs/threads/threadmanager.cpp:196
#7  0x00007fe813f2d6bd in QThreadPoolThread::run (this=0x7fe7cc22bb70) at concurrent/qthreadpool.cpp:107
#8  0x00007fe813f39d0b in QThreadPrivate::start (arg=0x7fe7cc22bb70) at thread/qthread_unix.cpp:307
#9  0x00007fe812bbdb50 in start_thread (arg=<optimized out>) at pthread_create.c:304
#10 0x00007fe8131eca7d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112
#11 0x0000000000000000 in ?? ()

Thread 1 (Thread 0x7fe8191b7a00 (LWP 14352)):
[KCrash Handler]
#6  0x00007fe814a6daea in parent (this=0x7fe7cc09a230) at ../../include/QtCore/../../src/corelib/kernel/qobject.h:273
#7  parentWidget (this=0x7fe7cc09a230) at ../../include/QtGui/../../src/gui/kernel/qwidget.h:1033
#8  QLayout::addChildWidget (this=<optimized out>, w=0x7fe7cc09a230) at kernel/qlayout.cpp:992
#9  0x00007fe814a51156 in QBoxLayout::insertWidget (this=0x7fe7cc150610, index=index@entry=-1, widget=0x7fe7cc09a230, stretch=0, alignment=...) at kernel/qboxlayout.cpp:1032
#10 0x00007fe814a513bb in QBoxLayout::addWidget (this=<optimized out>, widget=<optimized out>, stretch=<optimized out>, alignment=...) at kernel/qboxlayout.cpp:1112
#11 0x00007fe7de1db51e in ?? () from /usr/lib/libksane.so.0
#12 0x00007fe7de1d75fa in KSaneIface::KSaneWidget::openDevice(QString const&) () from /usr/lib/libksane.so.0
#13 0x00007fe7de47f26d in KIPIAcquireImagesPlugin::Plugin_AcquireImages::slotActivate (this=0x4535fd0) at /home/ag/src/digikam-2.9.0/extra/kipi-plugins/acquireimages/plugin_acquireimages.cpp:115
#14 0x00007fe81404a54f in QMetaObject::activate (sender=0x454ff80, m=<optimized out>, local_signal_index=<optimized out>, argv=0x7fff56ab8010) at kernel/qobject.cpp:3547
#15 0x00007fe814a3e502 in QAction::triggered (this=this@entry=0x454ff80, _t1=false) at .moc/release-shared/moc_qaction.cpp:277
#16 0x00007fe814a3e6f0 in QAction::activate (this=0x454ff80, event=<optimized out>) at kernel/qaction.cpp:1257
#17 0x00007fe814e78413 in QMenuPrivate::activateCausedStack (this=this@entry=0x7fe7e81a1bc0, causedStack=..., action=action@entry=0x454ff80, action_e=action_e@entry=QAction::Trigger, self=self@entry=true) at widgets/qmenu.cpp:1028
#18 0x00007fe814e7e729 in QMenuPrivate::activateAction (this=0x7fe7e81a1bc0, action=0x454ff80, action_e=QAction::Trigger, self=true) at widgets/qmenu.cpp:1120
#19 0x00007fe815830340 in KMenu::mouseReleaseEvent (this=0x7fe7e82860d0, e=0x7fff56ab8bb0) at ../../kdeui/widgets/kmenu.cpp:464
#20 0x00007fe814a93e10 in QWidget::event (this=0x7fe7e82860d0, event=0x7fff56ab8bb0) at kernel/qwidget.cpp:8371
#21 0x00007fe814e7f9db in QMenu::event (this=0x7fe7e82860d0, e=0x7fff56ab8bb0) at widgets/qmenu.cpp:2469
#22 0x00007fe814a4470c in QApplicationPrivate::notify_helper (this=this@entry=0x27424e0, receiver=receiver@entry=0x7fe7e82860d0, e=e@entry=0x7fff56ab8bb0) at kernel/qapplication.cpp:4556
#23 0x00007fe814a493eb in QApplication::notify (this=<optimized out>, receiver=0x7fe7e82860d0, e=0x7fff56ab8bb0) at kernel/qapplication.cpp:4099
#24 0x00007fe815777886 in KApplication::notify (this=0x7fff56ab9ce0, receiver=0x7fe7e82860d0, event=0x7fff56ab8bb0) at ../../kdeui/kernel/kapplication.cpp:311
#25 0x00007fe814034b5e in QCoreApplication::notifyInternal (this=0x7fff56ab9ce0, receiver=0x7fe7e82860d0, event=0x7fff56ab8bb0) at kernel/qcoreapplication.cpp:915
#26 0x00007fe814a4554b in sendEvent (event=<optimized out>, receiver=<optimized out>) at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:231
#27 QApplicationPrivate::sendMouseEvent (receiver=0x7fe7e82860d0, event=0x7fff56ab8bb0, alienWidget=0x0, nativeWidget=0x7fe7e82860d0, buttonDown=0x7fe81551a2a8, lastMouseReceiver=..., spontaneous=true) at kernel/qapplication.cpp:3167
#28 0x00007fe814abfe8c in QETWidget::translateMouseEvent (this=this@entry=0x7fe7e82860d0, event=event@entry=0x7fff56ab9320) at kernel/qapplication_x11.cpp:4457
#29 0x00007fe814abed51 in QApplication::x11ProcessEvent (this=0x7fff56ab9ce0, event=0x7fff56ab9320) at kernel/qapplication_x11.cpp:3646
#30 0x00007fe814ae5bc2 in x11EventSourceDispatch (s=0x2743700, callback=0, user_data=0x0) at kernel/qguieventdispatcher_glib.cpp:146
#31 0x00007fe80c5ac355 in g_main_context_dispatch () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#32 0x00007fe80c5ac688 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#33 0x00007fe80c5ac744 in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#34 0x00007fe814063276 in QEventDispatcherGlib::processEvents (this=0x26e0be0, flags=...) at kernel/qeventdispatcher_glib.cpp:424
#35 0x00007fe814ae583e in QGuiEventDispatcherGlib::processEvents (this=<optimized out>, flags=...) at kernel/qguieventdispatcher_glib.cpp:204
#36 0x00007fe8140338af in QEventLoop::processEvents (this=this@entry=0x7fff56ab96f0, flags=...) at kernel/qeventloop.cpp:149
#37 0x00007fe814033b38 in QEventLoop::exec (this=0x7fff56ab96f0, flags=...) at kernel/qeventloop.cpp:204
#38 0x00007fe814038cf8 in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1187
#39 0x000000000069f74e in main (argc=5, argv=0x7fff56ab9f18) at /home/ag/src/digikam-2.9.0/core/digikam/main/main.cpp:232

Possible duplicates by query: bug 306144.

Reported using DrKonqi
Comment 1 Andrew Goodbody 2013-01-30 09:23:51 UTC
Created attachment 76804 [details]
New crash information added by DrKonqi

digikam (2.9.0) on KDE Platform 4.8.4 (4.8.4) using Qt 4.8.2

- What I was doing when the application crashed:

Segfault on 2nd launch of import from scanner after selecting which scanner to use.

-- Backtrace (Reduced):
#6  0x00007fa4cf453aea in parent (this=0x7fa488091340) at ../../include/QtCore/../../src/corelib/kernel/qobject.h:273
#7  parentWidget (this=0x7fa488091340) at ../../include/QtGui/../../src/gui/kernel/qwidget.h:1033
#8  QLayout::addChildWidget (this=<optimized out>, w=0x7fa488091340) at kernel/qlayout.cpp:992
#9  0x00007fa4cf437156 in QBoxLayout::insertWidget (this=0x7fa4880ae680, index=index@entry=-1, widget=0x7fa488091340, stretch=0, alignment=...) at kernel/qboxlayout.cpp:1032
#10 0x00007fa4cf4373bb in QBoxLayout::addWidget (this=<optimized out>, widget=<optimized out>, stretch=<optimized out>, alignment=...) at kernel/qboxlayout.cpp:1112
Comment 2 Andrew Goodbody 2013-01-30 09:23:52 UTC
Created attachment 76805 [details]
New crash information added by DrKonqi

digikam (2.9.0) on KDE Platform 4.8.4 (4.8.4) using Qt 4.8.2

- What I was doing when the application crashed:

Segfault on 2nd launch of import from scanner after selecting which scanner to use.

-- Backtrace (Reduced):
#6  0x00007fa4cf453aea in parent (this=0x7fa488091340) at ../../include/QtCore/../../src/corelib/kernel/qobject.h:273
#7  parentWidget (this=0x7fa488091340) at ../../include/QtGui/../../src/gui/kernel/qwidget.h:1033
#8  QLayout::addChildWidget (this=<optimized out>, w=0x7fa488091340) at kernel/qlayout.cpp:992
#9  0x00007fa4cf437156 in QBoxLayout::insertWidget (this=0x7fa4880ae680, index=index@entry=-1, widget=0x7fa488091340, stretch=0, alignment=...) at kernel/qboxlayout.cpp:1032
#10 0x00007fa4cf4373bb in QBoxLayout::addWidget (this=<optimized out>, widget=<optimized out>, stretch=<optimized out>, alignment=...) at kernel/qboxlayout.cpp:1112
Comment 3 Andrew Goodbody 2013-01-30 09:23:52 UTC
Created attachment 76806 [details]
New crash information added by DrKonqi

digikam (2.9.0) on KDE Platform 4.8.4 (4.8.4) using Qt 4.8.2

- What I was doing when the application crashed:

Segfault on 2nd launch of import from scanner after selecting which scanner to use.

-- Backtrace (Reduced):
#6  0x00007fa4cf453aea in parent (this=0x7fa488091340) at ../../include/QtCore/../../src/corelib/kernel/qobject.h:273
#7  parentWidget (this=0x7fa488091340) at ../../include/QtGui/../../src/gui/kernel/qwidget.h:1033
#8  QLayout::addChildWidget (this=<optimized out>, w=0x7fa488091340) at kernel/qlayout.cpp:992
#9  0x00007fa4cf437156 in QBoxLayout::insertWidget (this=0x7fa4880ae680, index=index@entry=-1, widget=0x7fa488091340, stretch=0, alignment=...) at kernel/qboxlayout.cpp:1032
#10 0x00007fa4cf4373bb in QBoxLayout::addWidget (this=<optimized out>, widget=<optimized out>, stretch=<optimized out>, alignment=...) at kernel/qboxlayout.cpp:1112
Comment 4 Andrew Goodbody 2013-01-30 09:28:20 UTC
Oops, KDE bug handler got a bit confused, those last three reports are all the same one.
Comment 5 Kåre Särs 2013-01-30 11:16:23 UTC
Hi,

Can you add debug packages for kdegraphics (libksane) and reproduce the crash?
The trace does not contain all the needed info for libksane.

Thanks,
  Kåre
Comment 6 Andrew Goodbody 2013-01-30 11:57:22 UTC
Created attachment 76811 [details]
New crash information added by DrKonqi

digikam (2.9.0) on KDE Platform 4.8.4 (4.8.4) using Qt 4.8.2

- What I was doing when the application crashed:

Segfault reproduced after adding debug symbols for libksane

-- Backtrace (Reduced):
#6  0x00007fa85b233aea in parent (this=0x3991e50) at ../../include/QtCore/../../src/corelib/kernel/qobject.h:273
#7  parentWidget (this=0x3991e50) at ../../include/QtGui/../../src/gui/kernel/qwidget.h:1033
#8  QLayout::addChildWidget (this=<optimized out>, w=0x3991e50) at kernel/qlayout.cpp:992
#9  0x00007fa85b217156 in QBoxLayout::insertWidget (this=0x3b5e300, index=index@entry=-1, widget=0x3991e50, stretch=0, alignment=...) at kernel/qboxlayout.cpp:1032
#10 0x00007fa85b2173bb in QBoxLayout::addWidget (this=<optimized out>, widget=<optimized out>, stretch=<optimized out>, alignment=...) at kernel/qboxlayout.cpp:1112
Comment 7 Kåre Särs 2013-01-30 13:45:30 UTC
Thanks.

I need a bit more of the trace....
Comment 8 Andrew Goodbody 2013-01-30 15:46:55 UTC
The full trace is there as the attachment isn't it? If not, then how do I get it?
Comment 9 Kåre Särs 2013-01-30 17:52:36 UTC
Sorry I did not notice the attachment.

I can now also reproduce the crash.
Comment 10 Kåre Särs 2013-01-30 20:09:45 UTC
Git commit 1642660ebc94be152462a0c2a6962f6ff553954a by Kåre Särs.
Committed on 30/01/2013 at 21:05.
Pushed by sars into branch 'master'.

Prevent the use from opening two devices with the same KSaneWidget

M  +5    -0    libksane/ksane_widget.cpp

http://commits.kde.org/libksane/1642660ebc94be152462a0c2a6962f6ff553954a
Comment 11 Kåre Särs 2013-01-30 20:31:26 UTC
Git commit 0ff379e9e1d937e56d64bd5a2bea58ebb32dc2ed by Kåre Särs.
Committed on 30/01/2013 at 21:28.
Pushed by sars into branch 'master'.

Make sure the scanner device is closed when the dialog is closed

M  +9    -0    acquireimages/scandialog.cpp
M  +1    -0    acquireimages/scandialog.h

http://commits.kde.org/kipi-plugins/0ff379e9e1d937e56d64bd5a2bea58ebb32dc2ed
Comment 12 Kåre Särs 2013-02-11 16:00:53 UTC
Git commit 3a8351e3b0fc5159d0206b124c04b21c21b10bc2 by Kåre Särs.
Committed on 30/01/2013 at 21:05.
Pushed by sars into branch 'KDE/4.10'.

Prevent the use from opening two devices with the same KSaneWidget

M  +5    -0    libksane/ksane_widget.cpp

http://commits.kde.org/libksane/3a8351e3b0fc5159d0206b124c04b21c21b10bc2
Comment 13 Kåre Särs 2013-02-11 20:24:36 UTC
*** Bug 268283 has been marked as a duplicate of this bug. ***