[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Chicken-hackers] [PATCH] disable SIGPIPE for sockets in iOS
From: |
Peter Bex |
Subject: |
Re: [Chicken-hackers] [PATCH] disable SIGPIPE for sockets in iOS |
Date: |
Mon, 26 Aug 2013 16:47:35 +0200 |
User-agent: |
Mutt/1.4.2.3i |
Hi all,
I'm still awaiting feedback on this one...
On Fri, Jun 21, 2013 at 08:52:17PM +0200, Peter Bex wrote:
> On Mon, Jun 17, 2013 at 08:51:01AM +0200, Felix wrote:
> > The attached patch disables SIGPIPE for sockets, which appears
> > to be an iOS-specific "Feature", and uses setsockopt(2) with the
> > Mac/BSD-specific SO_NOSIGPIPE option. Pipe-errors are then returned
> > as EPIPE in the usual fashion.
>
> If I understand correctly, iOS will refuse to return EPIPE, relying
> solely on SIGPIPE?
>
> The patch didn't apply cleanly (it was against an old master from before
> some TCP FD leaks were fixed) but I managed to fix it. Find it attached
> with two additional modifications:
>
> 1) it disables SIGPIPE for all OSes (for consistency; on Linux/BSD
> you will get SIGPIPE _and_ EPIPE while on iOS you would only get EPIPE)
> 2) it does this for "client" sockets as well (not sure if this was an
> oversight or maybe iOS has this broken behaviour only for listening
> sockets?)
>
> I thought these additional changes might warrant further discussion, so
> I didn't just push them as-is.
Cheers,
Peter
--
http://www.more-magic.net
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [Chicken-hackers] [PATCH] disable SIGPIPE for sockets in iOS,
Peter Bex <=