]> git.ipfire.org Git - thirdparty/systemd.git/commit
systemctl: keep ignoring sessions on shutdown as root 34245/head
authorLuca Boccassi <bluca@debian.org>
Tue, 3 Sep 2024 23:02:46 +0000 (00:02 +0100)
committerLuca Boccassi <bluca@debian.org>
Fri, 13 Sep 2024 10:32:42 +0000 (12:32 +0200)
commitf2f9c199d100e0393c1909b00df4800b3ec0ca5c
tree5460e198eb8ee36c8dbb8d7a2dcf9fc1fed4cf18
parent5360db2a90c23898a93a888cc13230f77166f17a
systemctl: keep ignoring sessions on shutdown as root

The change was supposed to be about respecting inhibitors, but
it was extended to also error out when there are active user
sessions, which was not intentional. Previously systemctl skipped
all checks if the caller was root or root-equivalent. Restore the
previous behaviour and again avoid blocking systemctl reboot by root
if there are active sessions, as long as there are no active
inhibitors.

Fixes https://github.com/systemd/systemd/issues/34086

Follow-up for 804874d26ac73e0af07c4c5d7165c95372f03f6d
src/systemctl/systemctl-logind.c