]> err.no Git - systemd/commitdiff
manager: we are not interested in SIGSTOP notifications
authorLennart Poettering <lennart@poettering.net>
Tue, 13 Apr 2010 00:36:56 +0000 (02:36 +0200)
committerLennart Poettering <lennart@poettering.net>
Tue, 13 Apr 2010 00:36:56 +0000 (02:36 +0200)
manager.c

index 36733b0eb5be91e0509356074dfa9923d0054d5b..e7c66099a444c8a25901aa18776862d25ec126f7 100644 (file)
--- a/manager.c
+++ b/manager.c
@@ -72,9 +72,16 @@ static int enable_special_signals(Manager *m) {
 static int manager_setup_signals(Manager *m) {
         sigset_t mask;
         struct epoll_event ev;
+        struct sigaction sa;
 
         assert(m);
 
+        /* We are not interested in SIGSTOP and friends. */
+        zero(sa);
+        sa.sa_handler = SIG_DFL;
+        sa.sa_flags = SA_NOCLDSTOP|SA_RESTART;
+        assert_se(sigaction(SIGCHLD, &sa, NULL) == 0);
+
         assert_se(sigemptyset(&mask) == 0);
         assert_se(sigaddset(&mask, SIGCHLD) == 0);
         assert_se(sigaddset(&mask, SIGINT) == 0);   /* Kernel sends us this on control-alt-del */