Adopt BusyBox init signal handling for halt/reboot/poweroff

This patch adopts the BusyBox init signals for handling halt, reboot,
and poweroff.  The SIGINT and SIGPWR signals still behave the same as
before, even though they likely will become configurable in a future
release.

Note: the disabling of Ctrl-Alt-Delete (SIGINT) is also removed!

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
Joachim Nilsson committed 2016-07-29 16:47:38 +02:00
1 parent 0df0f019e3
commit eeb59eb22b
6 files changed
+144 -41

No files matched your search

+2 -2
View File
@@ -155,12 +155,12 @@ restart:
svc_clean_dynamic(service_unregister);
if (0 == runlevel) {
do_shutdown(SIGUSR2);
do_shutdown(SHUT_OFF);
sm->state = SM_RUNNING_STATE;
break;
}
if (6 == runlevel) {
do_shutdown(SIGUSR1);
do_shutdown(SHUT_REBOOT);
sm->state = SM_RUNNING_STATE;
break;
}