diff options
| author | Lennart Poettering <lennart@poettering.net> | 2009-10-18 04:21:21 +0200 | 
|---|---|---|
| committer | Lennart Poettering <lennart@poettering.net> | 2009-10-18 04:21:21 +0200 | 
| commit | 9c813442dd8ce4d140a114a06287cf52217daae1 (patch) | |
| tree | a8a7f8012bdeeac864d25830a40a1afef161c75c | |
| parent | 177db9cf9a7a27a10f427369f4b4ff851a03bcf7 (diff) | |
testd: use SIGTERM instead of SIGINT for shutting down daemon
| -rw-r--r-- | examples/testd.c | 6 | 
1 files changed, 3 insertions, 3 deletions
diff --git a/examples/testd.c b/examples/testd.c index 7e0d791..fde6195 100644 --- a/examples/testd.c +++ b/examples/testd.c @@ -54,10 +54,10 @@ int main(int argc, char *argv[]) {      if (argc >= 2 && !strcmp(argv[1], "-k")) {          int ret; -        /* Kill daemon with SIGINT */ +        /* Kill daemon with SIGTERM */          /* Check if the new function daemon_pid_file_kill_wait() is available, if it is, use it. */ -        if ((ret = daemon_pid_file_kill_wait(SIGINT, 5)) < 0) +        if ((ret = daemon_pid_file_kill_wait(SIGTERM, 5)) < 0)              daemon_log(LOG_WARNING, "Failed to kill daemon: %s", strerror(errno));          return ret < 0 ? 1 : 0; @@ -161,7 +161,7 @@ int main(int argc, char *argv[]) {                      case SIGINT:                      case SIGQUIT:                      case SIGTERM: -                        daemon_log(LOG_WARNING, "Got SIGINT, SIGQUIT or SIGTERM"); +                        daemon_log(LOG_WARNING, "Got SIGINT, SIGQUIT or SIGTERM.");                          quit = 1;                          break;  | 
