Bug 391643

Summary: Konsole occasionally crashes when closing it
Product: [Applications] konsole Reporter: Henningstone <henningstone>
Component: generalAssignee: Konsole Developer <konsole-devel>
Status: RESOLVED DUPLICATE    
Severity: normal CC: a.samirh78, luca.pedrielli
Priority: NOR Keywords: drkonqi
Version: 17.12.2   
Target Milestone: ---   
Platform: Neon   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Henningstone 2018-03-10 01:49:36 UTC
Application: kdeinit5 (17.12.2)

Qt Version: 5.10.0
Frameworks Version: 5.43.0
Operating System: Linux 4.13.0-36-generic x86_64
Distribution: KDE neon User Edition 5.12

-- Information about the crash:
When closing the program it occasionally crashes. The latest incident was on version 17.12.2 when simply closing the application window with multiple tabs open.
I've seen this kind of problem (same symptoms at least) on older versions before.

The crash can be reproduced sometimes.

-- Backtrace:
Application: Konsole (kdeinit5), signal: Segmentation fault
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[Current thread is 1 (Thread 0x7fdb20922780 (LWP 16980))]

Thread 2 (Thread 0x7fdb02659700 (LWP 16982)):
#0  0x00007fdb1e9eb27d in read () at ../sysdeps/unix/syscall-template.S:84
#1  0x00007fdb1ab8a073 in ?? () from /usr/lib/nvidia-384/tls/libnvidia-tls.so.384.111
#2  0x00007fdb1b0226f0 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#3  0x00007fdb1afdee74 in g_main_context_check () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x00007fdb1afdf330 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#5  0x00007fdb1afdf49c in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#6  0x00007fdb1efa05cb in QEventDispatcherGlib::processEvents (this=0x7fdafc0008e0, flags=...) at kernel/qeventdispatcher_glib.cpp:425
#7  0x00007fdb1ef4764a in QEventLoop::exec (this=this@entry=0x7fdb02658e10, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212
#8  0x00007fdb1ed67554 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:522
#9  0x00007fdb151ce2c5 in ?? () from /usr/lib/x86_64-linux-gnu/libQt5DBus.so.5
#10 0x00007fdb1ed6c6eb in QThreadPrivate::start (arg=0x7fdb15442d60) at thread/qthread_unix.cpp:376
#11 0x00007fdb1ce566ba in start_thread (arg=0x7fdb02659700) at pthread_create.c:333
#12 0x00007fdb1e9fb41d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 1 (Thread 0x7fdb20922780 (LWP 16980)):
[KCrash Handler]
#6  free_reply_list (head=0x1) at ../../src/xcb_in.c:363
#7  0x00007fdb1fd86bac in _xcb_map_delete (list=0x229ca50, do_free=do_free@entry=0x7fdb1fd84e00 <free_reply_list>) at ../../src/xcb_list.c:69
#8  0x00007fdb1fd8546d in _xcb_in_destroy (in=in@entry=0x229e2e0) at ../../src/xcb_in.c:901
#9  0x00007fdb1fd83875 in xcb_disconnect (c=0x229e2a0) at ../../src/xcb_conn.c:363
#10 0x00007fdb1ffb6677 in XCloseDisplay (dpy=0x229cee0) at ../../src/ClDisplay.c:71
#11 0x00007fdb0ce2e454 in QXcbConnection::~QXcbConnection (this=0x229cac0, __in_chrg=<optimized out>) at qxcbconnection.cpp:671
#12 0x00007fdb0ce2e489 in QXcbConnection::~QXcbConnection (this=0x229cac0, __in_chrg=<optimized out>) at qxcbconnection.cpp:678
#13 0x00007fdb0ce2ffa6 in qDeleteAll<QList<QXcbConnection*>::const_iterator> (end=..., begin=...) at ../../../../include/QtCore/../../src/corelib/tools/qalgorithms.h:320
#14 qDeleteAll<QList<QXcbConnection*> > (c=...) at ../../../../include/QtCore/../../src/corelib/tools/qalgorithms.h:328
#15 QXcbIntegration::~QXcbIntegration (this=0x226dfd0, __in_chrg=<optimized out>) at qxcbintegration.cpp:224
#16 0x00007fdb0ce300a9 in QXcbIntegration::~QXcbIntegration (this=0x226dfd0, __in_chrg=<optimized out>) at qxcbintegration.cpp:226
#17 0x00007fdb1f4d8333 in QGuiApplicationPrivate::~QGuiApplicationPrivate (this=0x2267490, __in_chrg=<optimized out>) at kernel/qguiapplication.cpp:1548
#18 0x00007fdb1d3c73e9 in QApplicationPrivate::~QApplicationPrivate (this=0x2267490, __in_chrg=<optimized out>) at kernel/qapplication.cpp:189
#19 0x00007fdb1ef7dedc in QScopedPointerDeleter<QObjectData>::cleanup (pointer=<optimized out>) at ../../include/QtCore/../../src/corelib/tools/qscopedpointer.h:60
#20 QScopedPointer<QObjectData, QScopedPointerDeleter<QObjectData> >::~QScopedPointer (this=0x2244ec8, __in_chrg=<optimized out>) at ../../include/QtCore/../../src/corelib/tools/qscopedpointer.h:107
#21 QObject::~QObject (this=<optimized out>, __in_chrg=<optimized out>) at kernel/qobject.cpp:881
#22 0x00007fdb1ef4b802 in QCoreApplication::~QCoreApplication (this=0x2244ec0, __in_chrg=<optimized out>) at kernel/qcoreapplication.cpp:877
#23 0x00007fdb1d3c92b4 in QApplication::~QApplication (this=0x2244ec0, __in_chrg=<optimized out>) at kernel/qapplication.cpp:800
#24 0x00007fdb1d3c9489 in QApplication::~QApplication (this=0x2244ec0, __in_chrg=<optimized out>) at kernel/qapplication.cpp:870
#25 0x00007fdb0df1d354 in kdemain (argc=3, argv=<optimized out>) at /workspace/build/src/main.cpp:191
#26 0x0000000000408679 in launch (argc=argc@entry=3, _name=_name@entry=0x2244548 "konsole", args=<optimized out>, args@entry=0x2244550 "--workdir", cwd=cwd@entry=0x2244581 "/home/henningstone/dev", envc=envc@entry=0, envs=<optimized out>, envs@entry=0x2244579 "", reset_env=false, tty=0x0, avoid_loops=false, startup_id_str=0x40b307 "0") at /workspace/build/src/kdeinit/kinit.cpp:705
#27 0x0000000000409c71 in handle_launcher_request (sock=9, who=who@entry=0x40b2bc "launcher") at /workspace/build/src/kdeinit/kinit.cpp:1147
#28 0x000000000040a307 in handle_requests (waitForPid=waitForPid@entry=0) at /workspace/build/src/kdeinit/kinit.cpp:1338
#29 0x0000000000404ee4 in main (argc=5, argv=<optimized out>) at /workspace/build/src/kdeinit/kinit.cpp:1784

Reported using DrKonqi
Comment 1 luca 2018-03-10 08:47:34 UTC
I can reproduce this bug every time.
Dolphin->Open Konsole(shift+f4)->Close Konsole.

---------------------------------------------------------------------
Application: kdeinit5 (kdeinit5), signal: Segmentation fault
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[KCrash Handler]
#6  0x00007fe359aa7abc in ?? () from /usr/lib/x86_64-linux-gnu/libnvidia-glcore.so.340.106
#7  0x00007fe359aa6ccf in ?? () from /usr/lib/x86_64-linux-gnu/libnvidia-glcore.so.340.106
#8  0x00007fe35d34c0a0 in ?? () from /usr/lib/x86_64-linux-gnu/libGL.so.1
#9  0x00007fe360ebf2d3 in ?? () from /lib64/ld-linux-x86-64.so.2
#10 0x00007fe35f0d0831 in ?? () from /lib/x86_64-linux-gnu/libc.so.6
#11 0x00007fe35f0d092a in exit () from /lib/x86_64-linux-gnu/libc.so.6
#12 0x0000561d290ce6a4 in ?? ()
#13 0x0000561d290cfc8b in ?? ()
#14 0x0000561d290d051b in ?? ()
#15 0x0000561d290cb00c in ?? ()
#16 0x00007fe35f0baa87 in __libc_start_main () from /lib/x86_64-linux-gnu/libc.so.6
#17 0x0000561d290cbc7a in _start ()
---------------------------------------------------------------------

debian testing
Plasma 5.12.2
Frameworks 5.42
Qt. 5.9.2

Nvidia driver 340.106-2

if dbgsym package are needed please tell me which ones, I will attach a more usefull crash log.
Comment 2 Henningstone 2018-03-10 16:16:42 UTC
I have used the button in DrKonqi to install debug symbols but that only got me 2 out of 3 stars so I guessed what else could be needed. The backtrace in my report was generated with the following installed (although not all may be needed):
- kinit-dbgsym
- konsole-dbgsym
- libqt5core5a-dbgsym
- libqt5gui5-dbgsym
- libqt5qml5-dbgsym
- libqt5widgets5-dbgsym
- plasma-framework-dbgsym

I'm on KDE Neon User Edition 5.12.3
KDE-Framework 5.43.0
Qt 5.10.0
NVidia driver 384.111
Comment 3 luca 2018-03-10 16:29:16 UTC
thanks for the reply.
i've tried also with your dbgsym file, but doesn't help.
it seems that mine is a different situation. i've opened another bugreport
bug 391664
Comment 4 Henningstone 2018-03-25 14:44:27 UTC
I have just had Konsole crash after closing it on my 5.8 system. Interesting how there is a lot of nvidia drivers stuff in this backtrace as well...

System:
 Linux Mint 18.3
 Plasma 5.8.9
 KDE-Framework 5.36.0
 Qt 5.6.1
 NVidia driver 384.111
 Konsole 16.04.3


Application: Konsole (konsole), signal: Aborted
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[Current thread is 1 (Thread 0x7f23b7a9d940 (LWP 23679))]

Thread 3 (Thread 0x7f23b491e700 (LWP 23681)):
[KCrash Handler]
#6  0x00007f23c9f1f428 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:54
#7  0x00007f23c9f2102a in __GI_abort () at abort.c:89
#8  0x00007f23c9f617ea in __libc_message (do_abort=do_abort@entry=2, fmt=fmt@entry=0x7f23ca07aed8 "*** Error in `%s': %s: 0x%s ***\n") at ../sysdeps/posix/libc_fatal.c:175
#9  0x00007f23c9f6a37a in malloc_printerr (ar_ptr=<optimized out>, ptr=<optimized out>, str=0x7f23ca07afe8 "double free or corruption (out)", action=3) at malloc.c:5006
#10 _int_free (av=<optimized out>, p=<optimized out>, have_lock=0) at malloc.c:3867
#11 0x00007f23c9f6e53c in __GI___libc_free (mem=<optimized out>) at malloc.c:2968
#12 0x00007f23bd64aae6 in _nv007tls () from /usr/lib/nvidia-384/tls/libnvidia-tls.so.384.111
#13 0x00007f23c2128439 in __nptl_deallocate_tsd () at pthread_create.c:175
#14 0x00007f23c2129870 in __nptl_deallocate_tsd () at pthread_create.c:326
#15 start_thread (arg=0x7f23b491e700) at pthread_create.c:346
#16 0x00007f23c9ff141d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 2 (Thread 0x7f23b7a99700 (LWP 23680)):
[KCrash Handler]
#5  malloc_consolidate (av=av@entry=0x7f23b0000020) at malloc.c:4169
#6  0x00007f23c9f6bcde in _int_malloc (av=av@entry=0x7f23b0000020, bytes=bytes@entry=2032) at malloc.c:3450
#7  0x00007f23c9f6edca in __libc_calloc (n=<optimized out>, elem_size=<optimized out>) at malloc.c:3236
#8  0x00007f23bd64c3e3 in ?? () from /usr/lib/nvidia-384/tls/libnvidia-tls.so.384.111
#9  0x00007f23c19f5771 in g_malloc0 () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#10 0x00007f23c1a0d2bd in g_slice_free1 () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
#11 0x00007f23c2128439 in __nptl_deallocate_tsd () at pthread_create.c:175
#12 0x00007f23c2129870 in __nptl_deallocate_tsd () at pthread_create.c:326
#13 start_thread (arg=0x7f23b7a99700) at pthread_create.c:346
#14 0x00007f23c9ff141d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109

Thread 1 (Thread 0x7f23b7a9d940 (LWP 23679)):
#0  0x00007f23bd64ae15 in _nv014tls () from /usr/lib/nvidia-384/tls/libnvidia-tls.so.384.111
#1  0x00007f23c10807cd in ?? () from /usr/lib/nvidia-384/libGL.so.1
#2  0x00007f23c1080bab in ?? () from /usr/lib/nvidia-384/libGL.so.1
#3  0x00007f23c1080c9a in ?? () from /usr/lib/nvidia-384/libGL.so.1
#4  0x00007f23c10c64da in ?? () from /usr/lib/nvidia-384/libGL.so.1
#5  0x00007f23ca509e05 in _dl_fini () at dl-fini.c:240
#6  0x00007f23c9f23ff8 in __run_exit_handlers (status=0, listp=0x7f23ca2ae5f8 <__exit_funcs>, run_list_atexit=run_list_atexit@entry=true) at exit.c:82
#7  0x00007f23c9f24045 in __GI_exit (status=<optimized out>) at exit.c:104
#8  0x00007f23c9f0a837 in __libc_start_main (main=0x4006c0, argc=2, argv=0x7fffb4908bd8, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7fffb4908bc8) at ../csu/libc-start.c:325
#9  0x00000000004006f9 in _start ()
Comment 5 Ahmad Samir 2018-03-25 15:40:10 UTC

*** This bug has been marked as a duplicate of bug 389272 ***