Bug 510785 - QThreadStorage errors after running "konsole --help"
Summary: QThreadStorage errors after running "konsole --help"
Status: CONFIRMED
Alias: None
Product: konsole
Classification: Applications
Component: general (other bugs)
Version First Reported In: 25.08.2
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Konsole Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-10-19 12:15 UTC by timofey
Modified: 2025-11-29 17:06 UTC (History)
2 users (show)

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


Attachments
screenshot of the observed result (162.67 KB, image/png)
2025-10-19 12:15 UTC, timofey
Details

Note You need to log in before you can comment on or make changes to this bug.
Description timofey 2025-10-19 12:15:41 UTC
Created attachment 185900 [details]
screenshot of the observed result

SUMMARY
When I launch console from the shell using arguments like
konsole --help
konsole --version

I get errors like these:
QThreadStorage: entry 8 destroyed before end of thread 0x555fa0013cc0
QThreadStorage: entry 4 destroyed before end of thread 0x555fa0013cc0
QThreadStorage: entry 3 destroyed before end of thread 0x555fa0013cc0

According to https://bugs.kde.org/show_bug.cgi?id=503421, this bug already existed and should have been fixed in QT 6.9. However, I have QT 6.10.0, and the bug is still present.

STEPS TO REPRODUCE
1. Run shell (in example, konsole)
2. write "konsole --version" or "konsole --help" in example
3. Get errors about QThreadStorage

OBSERVED RESULT
These errors are displayed after the main content.

EXPECTED RESULT
These errors are not displayed.

ADDITIONAL INFORMATION
Operating System: Arch Linux 
KDE Plasma Version: 6.4.5
KDE Frameworks Version: 6.19.0
Qt Version: 6.10.0
Kernel Version: 6.17.3-arch2-1 (64-bit)
Graphics Platform: Wayland
Processors: 6 × AMD Phenom(tm) II X6 1055T Processor
Memory: 16 ГиБ of RAM (15.6 ГиБ usable)
Graphics Processor: NVIDIA GeForce GTX 1050 Ti
Manufacturer: Gigabyte Technology Co., Ltd.
Product Name: GA-770T-D3L
Comment 1 Жора Змейкин 2025-10-19 13:12:43 UTC
I can reproduce this with Qt 6.9.2, and also with the Flathub and nightly KDE Flatpak versions of Konsole.

Operating System: ALT Linux 20250612
KDE Plasma Version: 6.4.5
KDE Frameworks Version: 6.18.0
Qt Version: 6.9.2
Kernel Version: 6.16.12-6.16-alt1 (64-bit)
Graphics Platform: Wayland
Processors: 4 × Intel® Core™ i5-5200U CPU @ 2.20GHz
Memory: 16 ГиБ of RAM (15.5 ГиБ usable)
Graphics Processor 1: Mesa Intel® HD Graphics 5500
Graphics Processor 2: Mesa Intel® HD Graphics 5500
Manufacturer: Acer
Product Name: Aspire E5-573G
System Version: V3.72
Comment 2 Christoph Cullmann 2025-11-29 16:28:38 UTC
Can reproduce in master with recent Qt, too:

❯ konsole --version
qt.multimedia.symbolsresolver: Couldn't load pipewire-0.3 library
qt.multimedia.symbolsresolver: Couldn't resolve pipewire-0.3 symbols
konsole 26.03.70
QThreadStorage: entry 3 destroyed before end of thread 0x559b0ae59f60
QThreadStorage: entry 2 destroyed before end of thread 0x559b0ae59f60

Same for Kate, that seems to be still a generic issue.

❯ kate --version   
qt.multimedia.symbolsresolver: Couldn't load pipewire-0.3 library
qt.multimedia.symbolsresolver: Couldn't resolve pipewire-0.3 symbols
kate 26.03.70
QThreadStorage: entry 1 destroyed before end of thread 0x555ea6c78370
QThreadStorage: entry 0 destroyed before end of thread 0x555ea6c78370
Comment 3 Christoph Cullmann 2025-11-29 16:43:46 UTC
My Qt is 6.10.1.
Comment 4 Christoph Cullmann 2025-11-29 17:01:42 UTC
gdb tells me:

#0  0x00007ffff4600986 in QMessageLogger::warning(char const*, ...) const () from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6Core.so.6
#1  0x00007ffff48d7a3b in QThreadStoragePrivate::finish(QList<void*>*) () from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6Core.so.6
#2  0x00007ffff48cf039 in void (anonymous namespace)::terminate_on_exception<QThreadPrivate::finish()::{lambda()#1}>(QThreadPrivate::finish()::{lambda()#1}&&) [clone .isra.0] ()
   from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6Core.so.6
#3  0x00007ffff48cf2de in (anonymous namespace)::QThreadDataDestroyer::EarlyMainThread::~EarlyMainThread() () from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6Core.so.6
#4  0x00007ffff3fd9d08 in __cxa_finalize () from /nix/store/xx7cm72qy2c0643cm1ipngd87aqwkcdp-glibc-2.40-66/lib/libc.so.6
#5  0x00007ffff4637db7 in __do_global_dtors_aux () from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6Core.so.6
#6  0x00007ffffff963e0 in ?? ()
#7  0x00007ffff7fc7102 in _dl_call_fini () from /nix/store/xx7cm72qy2c0643cm1ipngd87aqwkcdp-glibc-2.40-66/lib/ld-linux-x86-64.so.2
Comment 5 Christoph Cullmann 2025-11-29 17:04:49 UTC
Thread 3 (Thread 0x7fffec1106c0 (LWP 1845279) "WaylandEventThr"):
#0  0x00007ffff40aa43d in poll () from /nix/store/xx7cm72qy2c0643cm1ipngd87aqwkcdp-glibc-2.40-66/lib/libc.so.6
#1  0x00007fffee73cf3d in QtWaylandClient::EventThread::run() () from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6WaylandClient.so.6
#2  0x00007ffff48d02dc in QThreadPrivate::start(void*) () from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6Core.so.6
#3  0x00007ffff403097a in start_thread () from /nix/store/xx7cm72qy2c0643cm1ipngd87aqwkcdp-glibc-2.40-66/lib/libc.so.6
#4  0x00007ffff40b8d2c in __clone3 () from /nix/store/xx7cm72qy2c0643cm1ipngd87aqwkcdp-glibc-2.40-66/lib/libc.so.6

Thread 2 (Thread 0x7fffec9116c0 (LWP 1845278) "WaylandEventThr"):
#0  0x00007ffff402d389 in __futex_abstimed_wait_common () from /nix/store/xx7cm72qy2c0643cm1ipngd87aqwkcdp-glibc-2.40-66/lib/libc.so.6
#1  0x00007ffff402fe1e in pthread_cond_wait@@GLIBC_2.3.2 () from /nix/store/xx7cm72qy2c0643cm1ipngd87aqwkcdp-glibc-2.40-66/lib/libc.so.6
#2  0x00007ffff48d8d44 in QWaitCondition::wait(QMutex*, QDeadlineTimer) () from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6Core.so.6
#3  0x00007fffee73cef0 in QtWaylandClient::EventThread::run() () from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6WaylandClient.so.6
#4  0x00007ffff48d02dc in QThreadPrivate::start(void*) () from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6Core.so.6
#5  0x00007ffff403097a in start_thread () from /nix/store/xx7cm72qy2c0643cm1ipngd87aqwkcdp-glibc-2.40-66/lib/libc.so.6
#6  0x00007ffff40b8d2c in __clone3 () from /nix/store/xx7cm72qy2c0643cm1ipngd87aqwkcdp-glibc-2.40-66/lib/libc.so.6

Thread 1 (Thread 0x7fffecc98280 (LWP 1845217) "konsole"):
#0  0x00007ffff4600986 in QMessageLogger::warning(char const*, ...) const () from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6Core.so.6
#1  0x00007ffff48d7a3b in QThreadStoragePrivate::finish(QList<void*>*) () from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6Core.so.6
#2  0x00007ffff48cf039 in void (anonymous namespace)::terminate_on_exception<QThreadPrivate::finish()::{lambda()#1}>(QThreadPrivate::finish()::{lambda()#1}&&) [clone .isra.0] () from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6Core.so.6
#3  0x00007ffff48cf2de in (anonymous namespace)::QThreadDataDestroyer::EarlyMainThread::~EarlyMainThread() () from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6Core.so.6
#4  0x00007ffff3fd9d08 in __cxa_finalize () from /nix/store/xx7cm72qy2c0643cm1ipngd87aqwkcdp-glibc-2.40-66/lib/libc.so.6
#5  0x00007ffff4637db7 in __do_global_dtors_aux () from /nix/store/zp6r9bxds1hldvkx1vbrk0d1ady17zhh-qtbase-6.10.1/lib/libQt6Core.so.6
#6  0x00007ffffff963e0 in ?? ()
#7  0x00007ffff7fc7102 in _dl_call_fini () from /nix/store/xx7cm72qy2c0643cm1ipngd87aqwkcdp-glibc-2.40-66/lib/ld-linux-x86-64.so.2
Comment 6 Christoph Cullmann 2025-11-29 17:06:30 UTC
Could that be a side effect that --version exits perhaps in some bad way?