You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Jim Jagielski <ji...@jaguNET.com> on 1997/01/26 23:28:18 UTC
SO_DONTLINGER
Aha.... seems it simply does a SO_LINGER with a timer of 0, ie:
disabling SO_LINGER and maintaining the default method.
Oh well.
--
====================================================================
Jim Jagielski | jaguNET Access Services
jim@jaguNET.com | http://www.jaguNET.com/
"Not the Craw... the CRAW!"
Re: SO_DONTLINGER
Posted by Marc Slemko <ma...@znep.com>.
AFAIK, what a SO_LINGER with a timer of 0 generally does is drop a
connection violently; ie. send a RST and get rid of it _now_. The normal
behavior is between that and a SO_LINGER with a timeout.
FreeBSD tcp_usrreeq.c:
struct tcpcb *
tcp_disconnect(tp)
register struct tcpcb *tp;
{
struct socket *so = tp->t_inpcb->inp_socket;
if (tp->t_state < TCPS_ESTABLISHED)
tp = tcp_close(tp);
else if ((so->so_options & SO_LINGER) && so->so_linger == 0)
tp = tcp_drop(tp, 0);
else {
soisdisconnecting(so);
sbflush(&so->so_rcv);
tp = tcp_usrclosed(tp);
if (tp)
(void) tcp_output(tp);
}
return (tp);
}
[...]
/*
* Drop a TCP connection, reporting
* the specified error. If connection is synchronized,
* then send a RST to peer.
*/
struct tcpcb *
tcp_drop(tp, errno)
[...]
Perhaps.
On Sun, 26 Jan 1997, Jim Jagielski wrote:
> Aha.... seems it simply does a SO_LINGER with a timer of 0, ie:
> disabling SO_LINGER and maintaining the default method.
>
> Oh well.
> --
> ====================================================================
> Jim Jagielski | jaguNET Access Services
> jim@jaguNET.com | http://www.jaguNET.com/
> "Not the Craw... the CRAW!"
>