diff options
author | andre <andre@FreeBSD.org> | 2007-06-09 19:39:14 +0000 |
---|---|---|
committer | andre <andre@FreeBSD.org> | 2007-06-09 19:39:14 +0000 |
commit | e8333a59d1ace09b4998aafca6c29d5fd5ccb23d (patch) | |
tree | 6e5f8c844161d7851127721a3cce877e0488410c /sys/netinet/tcp_output.c | |
parent | c105658c88a2c2055d81325040ae51c145564d21 (diff) | |
download | FreeBSD-src-e8333a59d1ace09b4998aafca6c29d5fd5ccb23d.zip FreeBSD-src-e8333a59d1ace09b4998aafca6c29d5fd5ccb23d.tar.gz |
Don't send pure window updates when the peer has closed the connection
and won't ever send more data.
Diffstat (limited to 'sys/netinet/tcp_output.c')
-rw-r--r-- | sys/netinet/tcp_output.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/netinet/tcp_output.c b/sys/netinet/tcp_output.c index acd99d0..d8adff3 100644 --- a/sys/netinet/tcp_output.c +++ b/sys/netinet/tcp_output.c @@ -528,8 +528,11 @@ after_sack_rexmit: * max size segments, or at least 50% of the maximum possible * window, then want to send a window update to peer. * Skip this if the connection is in T/TCP half-open state. + * Don't send pure window updates when the peer has closed + * the connection and won't ever send more data. */ - if (recwin > 0 && !(tp->t_flags & TF_NEEDSYN)) { + if (recwin > 0 && !(tp->t_flags & TF_NEEDSYN) && + !TCPS_HAVERCVDFIN(tp->t_state)) { /* * "adv" is the amount we can increase the window, * taking into account that we are limited by |