aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/tcp/tcp.c
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2020-02-13 19:24:58 +0000
committerDave Barach <openvpp@barachs.net>2020-02-14 21:36:25 +0000
commit3f78bbb8e875f3fccbcd167289ba2d307cb86263 (patch)
treeb314ac3ae1eeb3ef4e332624fed77750dbdd520a /src/vnet/tcp/tcp.c
parent774b5dbe7f2f69eabb38fee300f32dc7ee687e7f (diff)
tcp: reset fin-wait-2 timeout connections
Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Id931f3f308a01788d222d0d62f26f5c579321c6a
Diffstat (limited to 'src/vnet/tcp/tcp.c')
-rw-r--r--src/vnet/tcp/tcp.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/vnet/tcp/tcp.c b/src/vnet/tcp/tcp.c
index f83f00aa695..e34f773d7d3 100644
--- a/src/vnet/tcp/tcp.c
+++ b/src/vnet/tcp/tcp.c
@@ -1431,6 +1431,14 @@ tcp_timer_waitclose_handler (u32 conn_index, u32 thread_index)
session_transport_closed_notify (&tc->connection);
tcp_worker_stats_inc (thread_index, to_closing, 1);
break;
+ case TCP_STATE_FIN_WAIT_2:
+ tcp_send_reset (tc);
+ tcp_connection_timers_reset (tc);
+ tcp_connection_set_state (tc, TCP_STATE_CLOSED);
+ session_transport_closed_notify (&tc->connection);
+ tcp_timer_set (tc, TCP_TIMER_WAITCLOSE, tcp_cfg.cleanup_time);
+ tcp_worker_stats_inc (thread_index, to_finwait2, 1);
+ break;
default:
tcp_connection_del (tc);
break;