summaryrefslogtreecommitdiffstats
path: root/src/vnet/tcp/tcp.h
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2019-11-04 14:39:33 -0800
committerDave Barach <openvpp@barachs.net>2019-11-07 19:37:25 +0000
commitbf1f8b7f288c29bfcc128b1d09eae1c1eac2b7cc (patch)
treeafb5738a75822c4d4ae7243beeeabe6ede83c7e3 /src/vnet/tcp/tcp.h
parent5ed3fe3dd4320a7b4080f18de32ef491b5a1c7f0 (diff)
tcp: fix retransmit with no sacks
Type: fix Change-Id: I6f7df0d358f57f7feadb9b7a3fcffb99558b2af8 Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'src/vnet/tcp/tcp.h')
-rw-r--r--src/vnet/tcp/tcp.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/vnet/tcp/tcp.h b/src/vnet/tcp/tcp.h
index 4b0a0ddea53..f40388721b6 100644
--- a/src/vnet/tcp/tcp.h
+++ b/src/vnet/tcp/tcp.h
@@ -882,7 +882,8 @@ tcp_bytes_out (const tcp_connection_t * tc)
if (tcp_opts_sack_permitted (&tc->rcv_opts))
return tc->sack_sb.sacked_bytes + tc->sack_sb.lost_bytes;
else
- return tc->rcv_dupacks * tc->snd_mss;
+ return clib_min (tc->rcv_dupacks * tc->snd_mss,
+ tc->snd_nxt - tc->snd_una);
}
/**