X-Git-Url: https://git.decadent.org.uk/gitweb/?p=nfs-utils.git;a=blobdiff_plain;f=utils%2Fstatd%2Fstatd.c;h=cf30fe46d0a17c3da481346b85f3955dd1165d9f;hp=b57f71bb0091bf1bc46096e5dbb996d88cc33107;hb=a75c6d57688b6f4435bac41ffac7c3b8eab1aab1;hpb=06c962bc87aba28a3169be6a18ce8d52060b661f diff --git a/utils/statd/statd.c b/utils/statd/statd.c index b57f71b..cf30fe4 100644 --- a/utils/statd/statd.c +++ b/utils/statd/statd.c @@ -399,6 +399,11 @@ int main (int argc, char **argv) signal (SIGTERM, killer); /* 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);