Change to runlevel 0/6 on reboot/halt/poweroff

This patch fixes a long-standing issue with how Finit handles shutdown,
reboot and poweroff -- and even runlevel changes to runlevel 0 and 6.

Prior to this patch sig.c:do_shutdown() was called immediately on any
of the above events, disregarding any services that a user might have
wanted to run as part of the shutdown/reboot.

With this change the handling is unified in all frontends to instead
do a runlevel change followed by the do_shutdown() action.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
Joachim Nilsson committed 2016-09-18 11:50:07 +02:00
1 parent 2c1e9877f9
commit f7d6d269c7
6 files changed
+49 -50

No files matched your search

-2
View File
@@ -20,8 +20,6 @@ General
* Add halt/poweroff/shutdown symlinks to finit and convert reboot, but
only install symlinks if these tools don't already exist.
* Step state machine at shutdown instead of killing, same as shifting to
runlevel 0 or 6, then call external (newly installed?) tool to reboot.
* Add support for timed shutdown in Finit, including cancelled shutdown.
* SysV init and systemd use SIGUSR1 to restart their FIFO/D-Bus. Add
API restart to SIGHUP callback for the same functionality in Finit.