diff options
author | Florin Coras <fcoras@cisco.com> | 2017-11-27 04:34:14 -0500 |
---|---|---|
committer | Dave Barach <openvpp@barachs.net> | 2017-11-28 13:21:26 +0000 |
commit | f988e696149f42828444c69762c036d9684b6bb0 (patch) | |
tree | 8e62fbd53a713e64be7c0441f0399aa023a949d8 /src/vnet/tcp/tcp_input.c | |
parent | af6f93a4eb4740ac13b1d65eb44da442976fa809 (diff) |
tcp: fix retransmissions under buffer shortage
- add debugging scaffolding for simulating buffer shortage
Change-Id: Ice519d74f9c4e4094c4586c548185135b7bb5f2d
Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'src/vnet/tcp/tcp_input.c')
-rw-r--r-- | src/vnet/tcp/tcp_input.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/vnet/tcp/tcp_input.c b/src/vnet/tcp/tcp_input.c index 614b94a4b06..702a94f3a98 100644 --- a/src/vnet/tcp/tcp_input.c +++ b/src/vnet/tcp/tcp_input.c @@ -3001,6 +3001,9 @@ tcp46_input_inline (vlib_main_t * vm, vlib_node_runtime_t * node, goto done; } + vnet_buffer (b0)->tcp.hdr_offset = (u8 *) tcp0 + - (u8 *) vlib_buffer_get_current (b0); + /* Session exists */ if (PREDICT_TRUE (0 != tconn)) { @@ -3014,8 +3017,6 @@ tcp46_input_inline (vlib_main_t * vm, vlib_node_runtime_t * node, vnet_buffer (b0)->tcp.ack_number = clib_net_to_host_u32 (tcp0->ack_number); - vnet_buffer (b0)->tcp.hdr_offset = (u8 *) tcp0 - - (u8 *) vlib_buffer_get_current (b0); vnet_buffer (b0)->tcp.data_offset = n_advance_bytes0; vnet_buffer (b0)->tcp.data_len = n_data_bytes0; |