From: Lennart Poettering Date: Tue, 13 Apr 2010 00:01:28 +0000 (+0200) Subject: main: ignore SIGKILL and SIGPIPE so that nothing intereferes with us X-Git-Tag: v1~544 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=commitdiff_plain;h=078e45398127cfef1c146d39f634c45cbfee1b28 main: ignore SIGKILL and SIGPIPE so that nothing intereferes with us --- diff --git a/main.c b/main.c index 9323d45f7..7dbcc90d5 100644 --- a/main.c +++ b/main.c @@ -387,6 +387,10 @@ int main(int argc, char *argv[]) { /* Reset all signal handlers. */ assert_se(reset_all_signal_handlers() == 0); + /* If we are init, we can block sigkill. Yay. */ + signal(SIGKILL, SIG_IGN); + signal(SIGPIPE, SIG_IGN); + /* Close all open files */ assert_se(close_all_fds(NULL, 0) == 0);