1
0
Fork 0
mirror of https://github.com/pygos/init.git synced 2024-05-17 03:06:13 +02:00

initd: accept sigterm and simply initiate shutdown target

Signed-off-by: David Oberhollenzer <david.oberhollenzer@tele2.at>
This commit is contained in:
David Oberhollenzer 2018-08-24 16:54:54 +02:00
parent 25afc0b3d0
commit ec6264bad5

View file

@ -40,6 +40,9 @@ static void handle_signal(void)
supervisor_handle_exited(pid, status);
}
break;
case SIGTERM:
supervisor_set_target(TGT_SHUTDOWN);
break;
case SIGINT:
supervisor_set_target(TGT_REBOOT);
break;