Signed-off-by: Federico Simoncelli <fsimonce(a)redhat.com>
---
wdmd/main.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/wdmd/main.c b/wdmd/main.c
index 28fa042..1f1395a 100644
--- a/wdmd/main.c
+++ b/wdmd/main.c
@@ -1030,7 +1030,8 @@ static void process_signals(int ci)
return;
}
- if (fdsi.ssi_signo == SIGTERM) {
+ if ((fdsi.ssi_signo == SIGTERM) ||
+ (fdsi.ssi_signo == SIGINT)) {
if (!active_clients())
daemon_quit = 1;
}
@@ -1047,6 +1048,7 @@ static int setup_signals(void)
sigemptyset(&mask);
sigaddset(&mask, SIGTERM);
+ sigaddset(&mask, SIGINT);
sigaddset(&mask, SIGHUP);
rv = sigprocmask(SIG_BLOCK, &mask, NULL);
--
1.7.1