diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2001-05-21 10:24:52 +0000 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2001-05-21 10:24:52 +0000 |
commit | 31ab5ebe1eb914d3707af9901ddf1f9330ad7d98 (patch) | |
tree | 0b10c6d982511bba6f602035e8cd12cc440403b0 /daemon.c | |
parent | 9944ca8e0b1674291d32ccb83262a9f717d09e69 (diff) | |
download | fetchmail-31ab5ebe1eb914d3707af9901ddf1f9330ad7d98.tar.gz fetchmail-31ab5ebe1eb914d3707af9901ddf1f9330ad7d98.tar.bz2 fetchmail-31ab5ebe1eb914d3707af9901ddf1f9330ad7d98.zip |
Fix patches from HMH and others.
svn path=/trunk/; revision=3317
Diffstat (limited to 'daemon.c')
-rw-r--r-- | daemon.c | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -82,6 +82,11 @@ sigchld_handler (int sig) lastsig = SIGCHLD; } +/* + * This function is called by other parts of the program to + * setup the sigchld handler after a change to the signal context. + * This is done to improve robustness of the signal handling code. + */ void deal_with_sigchld(void) { RETSIGTYPE sigchld_handler(int); @@ -95,7 +100,7 @@ void deal_with_sigchld(void) /* set up to catch child process termination signals */ sa_new.sa_handler = sigchld_handler; #ifdef SA_RESTART /* SunOS 4.1 portability hack */ - sa_new.sa_flags = SA_RESTART; + sa_new.sa_flags = SA_RESTART | SA_NOCLDSTOP; #endif sigaction (SIGCHLD, &sa_new, NULL); #if defined(SIGPWR) |