From 7977cbb52c2d785abd0d85d9df5991e8f7cae441 Mon Sep 17 00:00:00 2001 From: YizhePKU Date: Sat, 16 Oct 2021 20:17:02 +0800 Subject: [PATCH] Fix autostart write path (#1979) * Fix autostart write path (flameshot-org#1975) * Fix formating --- src/utils/confighandler.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/utils/confighandler.cpp b/src/utils/confighandler.cpp index 0836eb40..77a2813e 100644 --- a/src/utils/confighandler.cpp +++ b/src/utils/confighandler.cpp @@ -250,9 +250,9 @@ void ConfigHandler::setStartupLaunch(const bool start) << process.readAll(); } #elif defined(Q_OS_LINUX) || defined(Q_OS_UNIX) - QString path = QStandardPaths::locate(QStandardPaths::GenericConfigLocation, - "autostart/", - QStandardPaths::LocateDirectory); + QString path = + QStandardPaths::writableLocation(QStandardPaths::GenericConfigLocation) + + "/autostart/"; QDir autostartDir(path); if (!autostartDir.exists()) { autostartDir.mkpath(".");