]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
logind: use RET_GATHER() at one more place
authorLennart Poettering <lennart@poettering.net>
Tue, 22 Oct 2024 16:11:25 +0000 (18:11 +0200)
committerLennart Poettering <lennart@poettering.net>
Tue, 22 Oct 2024 16:44:05 +0000 (18:44 +0200)
src/login/logind-session-dbus.c

index 0812cfc2c25b62fe2abaa675ef49454d8ffb2ec9..cc2d581bc5bd7a6f0603fa2a53cb0f4ac9edd88c 100644 (file)
@@ -889,14 +889,11 @@ int session_send_lock_all(Manager *m, bool lock) {
         assert(m);
 
         HASHMAP_FOREACH(session, m->sessions) {
-                int k;
 
                 if (!SESSION_CLASS_CAN_LOCK(session->class))
                         continue;
 
-                k = session_send_lock(session, lock);
-                if (k < 0)
-                        r = k;
+                RET_GATHER(r, session_send_lock(session, lock));
         }
 
         return r;