diff options
| author | erdgeist <> | 2013-04-26 16:19:31 +0000 |
|---|---|---|
| committer | erdgeist <> | 2013-04-26 16:19:31 +0000 |
| commit | 07f5ea21f6236893e31a0d8a5cdebf72ec86ef74 (patch) | |
| tree | 38552d616c1e45b06510246cc683dcf03effcab9 | |
| parent | d5c18232d1ca4e8106ad924d3bd574500c2fab8a (diff) | |
When being called from /etc/rc at boot time, jaildaemon wakes up SIG_IGN-ing SIGHUP. Fix this.
| -rw-r--r-- | jaildaemon.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/jaildaemon.c b/jaildaemon.c index 0843b37..f78d1b1 100644 --- a/jaildaemon.c +++ b/jaildaemon.c | |||
| @@ -116,6 +116,10 @@ static void fork_slave( int master_fd ) { | |||
| 116 | sa.sa_flags = SA_NOCLDWAIT; | 116 | sa.sa_flags = SA_NOCLDWAIT; |
| 117 | if( sigaction(SIGCHLD, &sa, NULL) == -1 ) | 117 | if( sigaction(SIGCHLD, &sa, NULL) == -1 ) |
| 118 | exerr( "Error: Can not enable auto reap." ); | 118 | exerr( "Error: Can not enable auto reap." ); |
| 119 | sigemptyset(&sa.sa_mask); | ||
| 120 | sa.sa_handler = SIG_DFL; | ||
| 121 | if( sigaction(SIGHUP, &sa, NULL) == -1 ) | ||
| 122 | exerr( "Error: Can not un-ignore SIGHUP." ); | ||
| 119 | 123 | ||
| 120 | /* Wait for command from master */ | 124 | /* Wait for command from master */ |
| 121 | while(1) { | 125 | while(1) { |
