mirror of
https://github.com/systemd/systemd.git
synced 2025-01-12 13:18:14 +03:00
logind: update the session state file before we send out the CreateSession() reply
https://bugs.freedesktop.org/show_bug.cgi?id=67273
This commit is contained in:
parent
e21fea24ae
commit
76e665855e
Notes:
Lennart Poettering
2013-10-04 17:11:46 +02:00
Backport: bugfix
2
TODO
2
TODO
@ -51,8 +51,6 @@ CGroup Rework Completion:
|
|||||||
|
|
||||||
Features:
|
Features:
|
||||||
|
|
||||||
* remove systemctl load-unit
|
|
||||||
|
|
||||||
* journalctl: instead --after-cursor= maybe have a --cursor=XYZ+1 syntax?
|
* journalctl: instead --after-cursor= maybe have a --cursor=XYZ+1 syntax?
|
||||||
|
|
||||||
* given that logind/machined now let PID 1 do all nasty work we can
|
* given that logind/machined now let PID 1 do all nasty work we can
|
||||||
|
@ -2368,9 +2368,8 @@ DBusHandlerResult bus_message_filter(
|
|||||||
dbus_set_error(&error, BUS_ERROR_JOB_FAILED, "Start job for unit %s failed with '%s'", unit, result);
|
dbus_set_error(&error, BUS_ERROR_JOB_FAILED, "Start job for unit %s failed with '%s'", unit, result);
|
||||||
session_send_create_reply(s, &error);
|
session_send_create_reply(s, &error);
|
||||||
}
|
}
|
||||||
}
|
} else
|
||||||
|
session_save(s);
|
||||||
session_save(s);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
session_add_to_gc_queue(s);
|
session_add_to_gc_queue(s);
|
||||||
|
@ -592,6 +592,10 @@ int session_send_create_reply(Session *s, DBusError *error) {
|
|||||||
return log_oom();
|
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))
|
if (!dbus_connection_send(s->manager->bus, reply, NULL))
|
||||||
return log_oom();
|
return log_oom();
|
||||||
|
|
||||||
|
@ -350,6 +350,10 @@ int machine_send_create_reply(Machine *m, DBusError *error) {
|
|||||||
return log_oom();
|
return log_oom();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Update the machine state file before we notify the client
|
||||||
|
* about the result. */
|
||||||
|
machine_save(m);
|
||||||
|
|
||||||
if (!dbus_connection_send(m->manager->bus, reply, NULL))
|
if (!dbus_connection_send(m->manager->bus, reply, NULL))
|
||||||
return log_oom();
|
return log_oom();
|
||||||
|
|
||||||
|
@ -551,9 +551,8 @@ DBusHandlerResult bus_message_filter(
|
|||||||
dbus_set_error(&error, BUS_ERROR_JOB_FAILED, "Start job for unit %s failed with '%s'", unit, result);
|
dbus_set_error(&error, BUS_ERROR_JOB_FAILED, "Start job for unit %s failed with '%s'", unit, result);
|
||||||
machine_send_create_reply(mm, &error);
|
machine_send_create_reply(mm, &error);
|
||||||
}
|
}
|
||||||
}
|
} else
|
||||||
|
machine_save(mm);
|
||||||
machine_save(mm);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
machine_add_to_gc_queue(mm);
|
machine_add_to_gc_queue(mm);
|
||||||
|
Loading…
Reference in New Issue
Block a user