chiark / gitweb /
logind: update the session state file before we send out the CreateSession() reply
[elogind.git] / src / login / logind-session-dbus.c
index 210f756..2cc4d85 100644 (file)
@@ -592,6 +592,10 @@ int session_send_create_reply(Session *s, DBusError *error) {
                         return log_oom();
         }
 
+        /* Update the state file before we notify the client about the
+         * result */
+        session_save(s);
+
         if (!dbus_connection_send(s->manager->bus, reply, NULL))
                 return log_oom();