Date: Mon, 24 Mar 2003 21:54:01 -0600 From: Dan Nelson <dnelson@allantgroup.com> To: Dave Hayes <dave@jetcafe.org> Cc: freebsd-questions@FreeBSD.ORG Subject: Re: SIGPIPE and threaded servers Message-ID: <20030325035401.GB22424@dan.emsphone.com> In-Reply-To: <200303250235.h2P2Zuuq056175@hokkshideh2.jetcafe.org> References: <200303250235.h2P2Zuuq056175@hokkshideh2.jetcafe.org>
next in thread | previous in thread | raw e-mail | index | archive | help
In the last episode (Mar 24), Dave Hayes said: > Dan Nelson <dnelson@allantgroup.com> writes: > > In the last episode (Mar 23), Dave Hayes said: > > > I have a relatively simple threaded TCP server that services high > > > volumes of requests. Currently it appears to randomly crash > > > receiving a SIGPIPE. > > But it's not doing what I want it to do. > > I don't want my process with all it's threads to terminate if I write > on a pipe with no reader. I want the write() to return EPIPE so I can > handle it there. It's not doing that currently. Installing a signal > handler doesn't work to get it to do that. Ignoring the signal > doesn't work. I've used both signal() and sigaction() semantics to no > avail. So what you're saying is that even if you ignore SIGPIPE, your process still dies with SIGPIPE? That definitely should not happen, and probably counts as a kernel bug (signal is not wrapped by libc_r so threads shouldn't affect anything). -- Dan Nelson dnelson@allantgroup.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030325035401.GB22424>
