#1151189 Qt5 applications crash due to erroneous fallback handling for fontconfig

Package:
libqt5gui5
Source:
libqt5gui5
Description:
Qt 5 GUI module
Submitter:
Michael Schuster
Date:
2026-10-17 22:29:02 UTC
Severity:
normal
#1151189#5
Date:
2026-10-17 22:17:24 UTC
From:
To:
Dear Maintainers (dear Dmitry, if I've just assembled my new package
knowledge correctly ;),

Qt has a confirmed bug in fallback handling for fontconfig that causes
arbitrary crashes in every Qt-based application.

Here is the respective debug trace snippet from my machine:

Thread 1 "keepassxc" received signal SIGSEGV, Segmentation fault.
0x00007ffff1e41d51 in ?? () from
/lib/x86_64-linux-gnu/libfontconfig.so.1
(gdb) bt
#0  0x00007ffff1e41d51 in ??? () at
/lib/x86_64-linux-gnu/libfontconfig.so.1
#1  0x00007ffff1e424f7 in FcCharSetHasChar () at
/lib/x86_64-linux-gnu/libfontconfig.so.1
#2  0x00007ffff1f6b900 in ??? () at
/lib/x86_64-linux-gnu/libQt5XcbQpa.so.5
#3  0x00007ffff682a383 in QFontEngineMulti::stringToCMap
(this=<optimized out>, str=<optimized out>, len=<optimized out>,
glyphs=<optimized out>, nglyphs=0x7fffffffb7fc, flags=...) at
text/qfontengine.cpp:1933

In my specific case KeePassXC suddenly began to crash when I tried to
open sub-folders or even when I only tried to select "About" within the
menu. This behaviour apparently started after the fontconfig package
received an update.

Some debugging and researching then lead to the discovery that this
indeed is a bug in Qt and that it luckily already has been fixed
upstream:
https://codereview.qt-project.org/c/qt/qtbase/+/750214

The commit:
https://code.qt.io/cgit/qt/qtbase.git/commit/?id=80ddc8dee6a05cd6

But sadly it only made it into the very recent Qt6 versions mentioned in
the commit.

I'm new to this and never have filed a bug for any distro before. Here
is what I've done so far:
- Built Qt5 and Qt6 from source and can confirm that the patch fixes the
issues (Qt5 drop-in replacement: libQt5XcbQpa.so.5.15.13).
- Followed these instructions to create a patch:

https://salsa.debian.org/qt-kde-team/qt/qtbase/-/blob/master/debian/README.source

There I've verified that the fix is not already part of debian/patches.

Now I would appreciate some guidance how to proceed with the patch /
backporting to other Qt versions, since all versions below Qt6 are
affected.

Is it sufficient to supply the patch (as attached to this mail)? I can
offer to create an account and merge request on Salsa, as well as help
backporting, if you like.

Note that I ran into the issue on Linux Mint 22.3 (Zena), based on
Ubuntu 24.04 (Noble), obviously based on Debian :)
So I would be grateful for any hints if and how I shall provide the
patch downstream as well. I'm actually a bit overwhelmed with all the
possible ways where, whom and how to provide the patch.

Please find the patch for Qt5 attached and let me know if I can assist
any further.

Thanks and have a great weekend,
Michael