Don't set FIN on a retransmitted segment after a FIN has been sent,

unless the segment really contains the last of the data for the stream.

PR:		kern/34619
Obtained from:	OpenBSD (tcp_output.c rev 1.47)
Noticed by:	Joseph Ishac
Reviewed by:	George Neville-Neil
This commit is contained in:
Bruce M Simpson 2004-06-18 02:47:59 +00:00
parent bd1a3f1a7e
commit da181cc144

View File

@ -292,7 +292,7 @@ again:
len = tp->t_maxseg;
sendalot = 1;
}
if (SEQ_LT(tp->snd_nxt + len, tp->snd_una + so->so_snd.sb_cc))
if (off + len < so->so_snd.sb_cc)
flags &= ~TH_FIN;
recwin = sbspace(&so->so_rcv);