Re: SO_LINGER patch for 2.2.15

From: Steve Underwood (steveu@coppice.org)
Date: Sat Feb 05 2000 - 12:46:51 EST


Andi Kleen wrote:

> stevek@SteveK.COM (Steve Kann) writes:
>
> > Hello, kernel-ites:
> >
> > I mentioned this in an earlier message titled "kernel blocks too
> > long with SO_LINGER", and since that time I did some investigation, and
> > have come to the conclusion that there is an error in the 2.2 kernel.
>
> There is never any "indefinate" block on close, because the retransmission
> timer for the FIN will kill (and wakeup) the sock after some time.
>
> IMHO the behaviour is correct, otherwise the application could not be
> sure that really all data has reached the other end. This way you are
> guaranteed to get a error return when data is lost.

I don't know what the standards say about this, but most Unixen don't tell
you if data failed to reach the other end. They just wait the appropriate
linger time, give up, and return from close without an error. I've never
found a reliable way to work out if the data actually got through. It a right
pain.

Steve

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Mon Feb 07 2000 - 21:00:12 EST