From a15b532a02094b3afe9d698f6b98e70f0fd4506a Mon Sep 17 00:00:00 2001 From: artoo Date: Thu, 13 Dec 2018 11:55:25 +0100 Subject: scripts: fix halt, poweroff and reboot wrappers These are designed to emulate the sysvinit equivalents, so pass "now" as the time argument if no arguments are given. This fixes #268. --- scripts/halt.in | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'scripts/halt.in') diff --git a/scripts/halt.in b/scripts/halt.in index 70e93662..209dc130 100644 --- a/scripts/halt.in +++ b/scripts/halt.in @@ -21,4 +21,9 @@ if [ -z "${poweroff_arg}" ]; then poweroff_arg=--poweroff fi -exec @SBINDIR@/openrc-shutdown ${option_arg} ${poweroff_arg} "$@" +script_args="$@" +if [ -z "${script_args}" ]; then + script_args=now +fi + +exec @SBINDIR@/openrc-shutdown ${option_arg} ${poweroff_arg} "${script_args}" -- cgit v1.2.3