Bug 269459

Summary: KGPG crashing on startup
Product: [Applications] kgpg Reporter: Nikolas Moraitis <drsys>
Component: generalAssignee: Rolf Eike Beer <kde>
Status: RESOLVED FIXED    
Severity: crash    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In: 4.7.3,4.8.0

Description Nikolas Moraitis 2011-03-26 12:49:15 UTC
Application: kgpg (2.4.1)
KDE Platform Version: 4.5.5 (KDE 4.5.5) (Compiled from sources)
Qt Version: 4.7.1
Operating System: Linux 2.6.35.11-83.fc14.x86_64 x86_64
Distribution: "Fedora release 14 (Laughlin)"

-- Information about the crash:
the application automatically starts on startup and reports an error :
gpg: /home/drsys/.gnupg/gpg.conf:4: argument not expected
gpg: /home/drsys/.gnupg/gpg.conf:5: invalid option
when trying to locate something ...
when i try to create a new keypair it also fails to do so

The crash can be reproduced every time.

-- Backtrace:
Application: KGpg (kgpg), signal: Segmentation fault
82	T_PSEUDO (SYSCALL_SYMBOL, SYSCALL_NAME, SYSCALL_NARGS)
[KCrash Handler]
#6  write (this=0x272eb20, a=<value optimized out>, lf=true) at /usr/include/QtCore/qiodevice.h:127
#7  KGpgTransaction::write (this=0x272eb20, a=<value optimized out>, lf=true) at /usr/src/debug/kdeutils-4.5.5/kgpg/transactions/kgpgtransaction.cpp:176
#8  0x0000000000445099 in KGpgGenerateKey::postStart (this=0x272eb20) at /usr/src/debug/kdeutils-4.5.5/kgpg/transactions/kgpggeneratekey.cpp:107
#9  0x000000000043ec32 in slotProcessStarted (this=0x272eb20, _c=QMetaObject::InvokeMetaMethod, _id=<value optimized out>, _a=0x7fff76c0caa0) at /usr/src/debug/kdeutils-4.5.5/kgpg/transactions/kgpgtransaction.cpp:130
#10 KGpgTransaction::qt_metacall (this=0x272eb20, _c=QMetaObject::InvokeMetaMethod, _id=<value optimized out>, _a=0x7fff76c0caa0) at /usr/src/debug/kdeutils-4.5.5/x86_64-redhat-linux-gnu/kgpg/kgpgtransaction.moc:90
#11 0x00007f9ae7f0504f in QMetaObject::activate (sender=0x2ac6a80, m=<value optimized out>, local_signal_index=<value optimized out>, argv=0x0) at kernel/qobject.cpp:3272
#12 0x00007f9ae7e8e575 in QProcessPrivate::_q_startupNotification (this=0x2bac260) at io/qprocess.cpp:1072
#13 0x00007f9ae7e93429 in QProcess::qt_metacall (this=0x2ac6a80, _c=QMetaObject::InvokeMetaMethod, _id=12, _a=0x7fff76c0cca0) at .moc/release-shared/moc_qprocess.cpp:113
#14 0x0000003743714748 in KProcess::qt_metacall (this=0x2ac6a80, _c=QMetaObject::InvokeMetaMethod, _id=<value optimized out>, _a=<value optimized out>) at /usr/src/debug/kdelibs-4.5.5/x86_64-redhat-linux-gnu/kdecore/kprocess.moc:69
#15 0x0000000000485eb8 in KLineBufferedProcess::qt_metacall (this=0x2ac6a80, _c=QMetaObject::InvokeMetaMethod, _id=<value optimized out>, _a=<value optimized out>) at /usr/src/debug/kdeutils-4.5.5/x86_64-redhat-linux-gnu/kgpg/klinebufferedprocess.moc:74
#16 0x0000000000485378 in GPGProc::qt_metacall (this=0x2ac6a80, _c=QMetaObject::InvokeMetaMethod, _id=<value optimized out>, _a=<value optimized out>) at /usr/src/debug/kdeutils-4.5.5/x86_64-redhat-linux-gnu/kgpg/gpgproc.moc:73
#17 0x00007f9ae7f0504f in QMetaObject::activate (sender=0x2bac9c0, m=<value optimized out>, local_signal_index=<value optimized out>, argv=0x7fff76c0cca0) at kernel/qobject.cpp:3272
#18 0x00007f9ae7f4d82e in QSocketNotifier::activated (this=<value optimized out>, _t1=19) at .moc/release-shared/moc_qsocketnotifier.cpp:89
#19 0x00007f9ae7f0b6cb in QSocketNotifier::event (this=0x2bac9c0, e=0x7fff76c0d350) at kernel/qsocketnotifier.cpp:317
#20 0x00007f9ae86528c4 in QApplicationPrivate::notify_helper (this=0x2638ac0, receiver=0x2bac9c0, e=0x7fff76c0d350) at kernel/qapplication.cpp:4445
#21 0x00007f9ae86573da in QApplication::notify (this=<value optimized out>, receiver=0x2bac9c0, e=0x7fff76c0d350) at kernel/qapplication.cpp:4324
#22 0x0000003746820596 in KApplication::notify (this=0x262f840, receiver=0x2bac9c0, event=0x7fff76c0d350) at /usr/src/debug/kdelibs-4.5.5/kdeui/kernel/kapplication.cpp:310
#23 0x00007f9ae7ef07ac in QCoreApplication::notifyInternal (this=0x262f840, receiver=0x2bac9c0, event=0x7fff76c0d350) at kernel/qcoreapplication.cpp:732
#24 0x00007f9ae7f1b289 in sendEvent (source=0x263bee0) at kernel/qcoreapplication.h:215
#25 socketNotifierSourceDispatch (source=0x263bee0) at kernel/qeventdispatcher_glib.cpp:110
#26 0x0000003738841e33 in g_main_context_dispatch () from /lib64/libglib-2.0.so.0
#27 0x0000003738842610 in ?? () from /lib64/libglib-2.0.so.0
#28 0x00000037388428ad in g_main_context_iteration () from /lib64/libglib-2.0.so.0
#29 0x00007f9ae7f1b8bf in QEventDispatcherGlib::processEvents (this=0x260cc20, flags=<value optimized out>) at kernel/qeventdispatcher_glib.cpp:415
#30 0x00007f9ae86f759e in QGuiEventDispatcherGlib::processEvents (this=<value optimized out>, flags=<value optimized out>) at kernel/qguieventdispatcher_glib.cpp:207
#31 0x00007f9ae7eefb42 in QEventLoop::processEvents (this=<value optimized out>, flags=...) at kernel/qeventloop.cpp:149
#32 0x00007f9ae7eefd8c in QEventLoop::exec (this=0x7fff76c0d590, flags=...) at kernel/qeventloop.cpp:201
#33 0x00007f9ae7ef424b in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1009
#34 0x0000000000476044 in main (argc=3, argv=0x7fff76c0da58) at /usr/src/debug/kdeutils-4.5.5/kgpg/main.cpp:57

Reported using DrKonqi
Comment 1 Rolf Eike Beer 2011-10-23 19:17:14 UTC
Git commit 988bcd6f5419f915ee9778270dd4f2acb57bb3b7 by Rolf Eike Beer.
Committed on 23/10/2011 at 21:14.
Pushed by dakon into branch 'master'.

check for GnuPG errors on startup

If GnuPG cannot run (e.g. because of configuration errors) everything bad can
happen. Explicitely check for this on startup and tell the user to fix his
GnuPG first.

BUG:269459
FIXED-IN:4.8.0

M  +6    -0    kgpg.cpp
M  +19   -0    kgpginterface.cpp
M  +7    -0    kgpginterface.h

http://commits.kde.org/kgpg/988bcd6f5419f915ee9778270dd4f2acb57bb3b7
Comment 2 Rolf Eike Beer 2011-10-23 19:27:28 UTC
I requested backport of this to 4.7, if all goes right this will also appear in 4.7.4.
Comment 3 Rolf Eike Beer 2011-10-24 06:36:28 UTC
Backported.