QKdeTheme: Don't leak resources on shutdown

The theme stores an array of pointers to allocated QFonts, which need to
be freed.

While this is not a "hard" leak (the OS will clean up the memory on
shutdown, and QKdeTheme lives as long as the application), it creates
ASAN warnings, which distract from more severe issues.

Change-Id: Iaa57138e5273c300c616ba85340283f18a267b09
Reviewed-by: Piotr Wierciński <piotr.wiercinski@qt.io>
This commit is contained in:
Fabian Kosmale 2025-03-21 13:28:41 +01:00
parent 930dfd11dd
commit fdb569a3e2

View File

@ -67,6 +67,7 @@ public:
};
QKdeThemePrivate(const QStringList &kdeDirs, int kdeVersion);
~QKdeThemePrivate() { clearResources(); }
static QString kdeGlobals(const QString &kdeDir, int kdeVersion)
{