mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-09-02 07:35:26 +00:00
Set default signal handlers for SIGINT and SIGTERM (SIGHUP already had one).
This doesn't appear to have an effect on any platform, but it seems like a good idea.
This commit is contained in:
@@ -15,7 +15,7 @@
|
|||||||
* SOFTWARE.
|
* SOFTWARE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* $Id: app.c,v 1.19 2000/06/29 07:40:58 explorer Exp $ */
|
/* $Id: app.c,v 1.20 2000/07/11 19:18:05 bwelling Exp $ */
|
||||||
|
|
||||||
#include <config.h>
|
#include <config.h>
|
||||||
|
|
||||||
@@ -152,11 +152,17 @@ isc_app_start(void) {
|
|||||||
/*
|
/*
|
||||||
* On Solaris 2, delivery of a signal whose action is SIG_IGN
|
* On Solaris 2, delivery of a signal whose action is SIG_IGN
|
||||||
* will not cause sigwait() to return. We may have inherited
|
* will not cause sigwait() to return. We may have inherited
|
||||||
* a SIG_IGN action for SIGHUP from our parent process,
|
* unexpected actions for SIGHUP, SIGINT, and SIGTERM from our parent
|
||||||
* (e.g, Solaris cron). Set an action of SIG_DFL to make
|
* process, * (e.g, Solaris cron). Set an action of SIG_DFL to make
|
||||||
* sure sigwait() works as expected.
|
* sure sigwait() works as expected.
|
||||||
*/
|
*/
|
||||||
result = handle_signal(SIGHUP, SIG_DFL);
|
result = handle_signal(SIGHUP, SIG_DFL);
|
||||||
|
if (result != ISC_R_SUCCESS)
|
||||||
|
return (result);
|
||||||
|
result = handle_signal(SIGTERM, SIG_DFL);
|
||||||
|
if (result != ISC_R_SUCCESS)
|
||||||
|
return (result);
|
||||||
|
result = handle_signal(SIGINT, SIG_DFL);
|
||||||
if (result != ISC_R_SUCCESS)
|
if (result != ISC_R_SUCCESS)
|
||||||
return (result);
|
return (result);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user