commit-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[hurd] 27/28: mach-defpager: Fix daemonization.


From: Samuel Thibault
Subject: [hurd] 27/28: mach-defpager: Fix daemonization.
Date: Wed, 16 Nov 2016 08:30:28 +0000

This is an automated email from the git hooks/post-receive script.

sthibault pushed a commit to branch upstream
in repository hurd.

commit 345abeda66c8aa5cb4d121fc8455cbe8053b9db6
Author: Justus Winter <address@hidden>
Date:   Tue Nov 1 16:29:31 2016 +0100

    mach-defpager: Fix daemonization.
    
    * mach-defpager/main.c (main): Do not hang if the child dies.
---
 mach-defpager/main.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/mach-defpager/main.c b/mach-defpager/main.c
index e33c2b3..71615c8 100644
--- a/mach-defpager/main.c
+++ b/mach-defpager/main.c
@@ -104,9 +104,11 @@ main (int argc, char **argv)
         exitting, and the child sends that signal after it is set up.  */
       sigset_t set;
       signal (SIGUSR1, nohandler);
+      signal (SIGCHLD, nohandler);
       sigemptyset (&set);
       sigaddset (&set, SIGUSR1);
-      sigprocmask (SIG_BLOCK, &set, 0);
+      sigaddset (&set, SIGCHLD);
+      sigprocmask (SIG_SETMASK, &set, NULL);
       switch (fork ())
        {
        case -1:

-- 
Alioth's /usr/local/bin/git-commit-notice on 
/srv/git.debian.org/git/pkg-hurd/hurd.git



reply via email to

[Prev in Thread] Current Thread [Next in Thread]