mirror of
https://github.com/clearlinux/systemd-stable.git
synced 2026-10-03 23:38:39 +00:00
systemctl: don't update the reboot parameter if none is given
Otherwise systemd-reboot.service will remove the parameter that was set
before. This was broken in commit "b986229efe2cc96157aa14c37bab7843311bbef1
systemctl: bugfix for systemctl reboot command with argument"
(cherry picked from commit c31c4324c5)
This commit is contained in:
committed by
Zbigniew Jędrzejewski-Szmek
parent
e341873c56
commit
27834dd75b
@@ -3031,7 +3031,7 @@ static int start_special(sd_bus *bus, char **args) {
|
||||
return -EPERM;
|
||||
}
|
||||
|
||||
if (a == ACTION_REBOOT) {
|
||||
if (a == ACTION_REBOOT && args[1]) {
|
||||
r = update_reboot_param_file(args[1]);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
Reference in New Issue
Block a user