From f9b5596b2763e33319134cfd9e9fd5e6bd124a0b Mon Sep 17 00:00:00 2001 From: Harald Sitter Date: Mon, 18 Sep 2023 10:56:47 +0200 Subject: [PATCH] greeter: disable qml disk cache The cache currently runs risk of getting corrupted and breaking the lock screen until the cache hash changes or the cache file gets removed by the user. Since we don't necessarily need a cache here let's just disable it for the time being in the interest of greater fault tolerance. BUG: 471952 (cherry picked from commit d1640daa360943f86196e323c4a76bde57566150) --- greeter/main.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/greeter/main.cpp b/greeter/main.cpp index f5c3c05c..6c2bff28 100644 --- a/greeter/main.cpp +++ b/greeter/main.cpp @@ -1,5 +1,6 @@ /* SPDX-FileCopyrightText: 2011 Martin Gräßlin +SPDX-FileCopyrightText: 2023 Harald Sitter SPDX-License-Identifier: GPL-2.0-or-later */ @@ -81,6 +82,10 @@ int main(int argc, char *argv[]) // Suppresses modal warnings about unwritable configuration files which may render the system inaccessible qputenv("KDE_HOME_READONLY", "1"); + // Disable QML caching to prevent cache corruption in full or near-full disk scenarios. + // https://bugs.kde.org/show_bug.cgi?id=471952 + // https://bugreports.qt.io/browse/QTBUG-117130 + qputenv("QML_DISABLE_DISK_CACHE", "1"); auto format = QSurfaceFormat::defaultFormat(); format.setOption(QSurfaceFormat::ResetNotification); -- GitLab