diff options
author | andre <andre@FreeBSD.org> | 2007-03-21 19:04:07 +0000 |
---|---|---|
committer | andre <andre@FreeBSD.org> | 2007-03-21 19:04:07 +0000 |
commit | 46edec2346d7678769ef5afe43c12651dbe830aa (patch) | |
tree | 49d228ab48ca205bd76df5ad7909aa163c41b623 /sys/netinet/tcp_output.c | |
parent | 8bf685df5173ea73a6f2755a9fb5ca54bc66ae72 (diff) | |
download | FreeBSD-src-46edec2346d7678769ef5afe43c12651dbe830aa.zip FreeBSD-src-46edec2346d7678769ef5afe43c12651dbe830aa.tar.gz |
Subtract optlen in the maximum length check for TSO and finally avoid
slightly oversized TSO mbuf chains.
Submitted by: kmacy
Diffstat (limited to 'sys/netinet/tcp_output.c')
-rw-r--r-- | sys/netinet/tcp_output.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/netinet/tcp_output.c b/sys/netinet/tcp_output.c index 7c52b8d..ac1649a 100644 --- a/sys/netinet/tcp_output.c +++ b/sys/netinet/tcp_output.c @@ -717,7 +717,7 @@ send: if (len + optlen + ipoptlen > tp->t_maxopd) { flags &= ~TH_FIN; if (tso) { - if (len > TCP_MAXWIN - hdrlen) { + if (len > TCP_MAXWIN - hdrlen - optlen) { len = TCP_MAXWIN - hdrlen - optlen; len = len - (len % (tp->t_maxopd - optlen)); sendalot = 1; |