diff options
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | utils/statd/statd.c | 5 |
2 files changed, 9 insertions, 0 deletions
@@ -1,3 +1,7 @@ +2004-12-03 Trond Myklebust <trond.myklebust@fys.uio.no> + + * utils/statd/statd.c(main): ignore SIGPIPE + 2004-11-22 "J. Bruce Fields" <bfields@fieldses.org> * tools/rpcdebug/rpcdebug.c: support aliases "nfsdebug" and diff --git a/utils/statd/statd.c b/utils/statd/statd.c index f666bcd..3f64115 100644 --- a/utils/statd/statd.c +++ b/utils/statd/statd.c @@ -422,6 +422,11 @@ int main (int argc, char **argv) signal(SIGUSR1, sigusr); /* WARNING: the following works on Linux and SysV, but not BSD! */ signal(SIGCHLD, SIG_IGN); + /* + * Ignore SIGPIPE to avoid statd dying when peers close their + * TCP connection while we're trying to reply to them. + */ + signal(SIGPIPE, SIG_IGN); /* initialize out_port */ statd_get_socket(out_port); |