diff options
author | Miles Bader <miles@gnu.org> | 1996-06-24 21:26:13 +0000 |
---|---|---|
committer | Miles Bader <miles@gnu.org> | 1996-06-24 21:26:13 +0000 |
commit | a13f5d0b8a4c4372936a92ef66f56b25530b8429 (patch) | |
tree | 80978f194009b68ece9a8c67a2f799ce2c2b010d /pfinet | |
parent | be7f748beac60afec491f21cfd3eacf48e088cbc (diff) |
(sigterm_handler):
Renamed from sighup_handle. Make void. Deal with SIGTERM instead of SIGHUP.
(main): Use SIGTERM & sigterm_handler instead of SIGHUP &c.
Diffstat (limited to 'pfinet')
-rw-r--r-- | pfinet/main.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/pfinet/main.c b/pfinet/main.c index cb770e17..0df713e4 100644 --- a/pfinet/main.c +++ b/pfinet/main.c @@ -81,8 +81,8 @@ S_startup_dosync (mach_port_t handle) return 0; } -int -sighup_handle (int signo) +void +sigterm_handler (int signo) { error_t do1 (void *port) @@ -94,9 +94,8 @@ sighup_handle (int signo) } ports_bucket_iterate (pfinet_bucket, do1); sleep (10); - signal (SIGHUP, SIG_DFL); - raise (SIGHUP); - return 0; + signal (SIGTERM, SIG_DFL); + raise (SIGTERM); } void @@ -109,7 +108,7 @@ arrange_shutdown_notification () shutdown_notify_class = ports_create_class (0, 0); - signal (SIGHUP, sighup_handler); + signal (SIGTERM, sigterm_handler); /* Arrange to get notified when the system goes down, but if we fail for some reason, just silently give up. No big deal. */ |