diff options
author | Florin Coras <fcoras@cisco.com> | 2019-10-28 08:46:37 -0700 |
---|---|---|
committer | Florin Coras <florin.coras@gmail.com> | 2019-10-28 16:58:58 +0000 |
commit | 5afea129ed0c85f5313791d1d55fed6cdcc079c7 (patch) | |
tree | f771c7edb28839ace73cceb65a61803e69de3d3b /src/vnet/session/session.c | |
parent | 1afe95272672ae0ff42109a9a682907fd169973e (diff) |
session: allow transport cleanup only if not deleted
Type: fix
Change-Id: I51282182952a66be698226bace39626df4d67b9f
Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'src/vnet/session/session.c')
-rw-r--r-- | src/vnet/session/session.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/vnet/session/session.c b/src/vnet/session/session.c index aff2cceaf14..1189d53b3cc 100644 --- a/src/vnet/session/session.c +++ b/src/vnet/session/session.c @@ -1282,8 +1282,9 @@ session_transport_cleanup (session_t * s) { /* Delete from main lookup table before we axe the the transport */ session_lookup_del_session (s); - transport_cleanup (session_get_transport_proto (s), s->connection_index, - s->thread_index); + if (s->session_state != SESSION_STATE_TRANSPORT_DELETED) + transport_cleanup (session_get_transport_proto (s), s->connection_index, + s->thread_index); /* Since we called cleanup, no delete notification will come. So, make * sure the session is properly freed. */ session_free_w_fifos (s); |