[plasma/plasma-nm] kded: secretagent: fix missing secrets returned

Marco Martin <[email protected]>
Newsgroups gmane.comp.kde.cvs
Message-ID <[email protected]>
Git commit c6e955a5f7e42b4e4f374631adb05e1e57e2138a by Marco Martin, on behalf of Mickaël Thomas.
Committed on 10/08/2026 at 10:48.
Pushed by mart into branch 'master'.

secretagent: fix missing secrets returned

A new GetSecrets request while a previous one was waiting on a QKeyChain
job would make the previous one return early with no secrets

M  +3    -1    kded/secretagent.cpp

https://invent.kde.org/plasma/plasma-nm/-/commit/c6e955a5f7e42b4e4f374631adb05e1e57e2138a

diff --git a/kded/secretagent.cpp b/kded/secretagent.cpp
index 1c48ad1f3..b548e478d 100644
--- a/kded/secretagent.cpp
+++ b/kded/secretagent.cpp
@@ -401,10 +401,12 @@ bool SecretAgent::processGetSecrets(QSharedPointer<SecretsRequest> request)
             job->setKey(storageKey(*connectionSettings, request->setting_name));
             job->start();
             return false;
-        } else {
+        } else if (request->storageJobsRunning <= 0) {
             for (auto it = request->storedSecrets.cbegin(); it != request->storedSecrets.cend(); ++it) {
                 secretsMap.insert(it.key(), it.value().toString());
             }
+        } else {
+            return false;
         }
     }
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.