summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2024-01-22 17:04:36 -0800
committerFlorin Coras <fcoras@cisco.com>2024-01-22 17:05:34 -0800
commit77680ae56f9c8854f5ed4290b971a43cf0fa8690 (patch)
treeacb023cddb0102754a8dc24eb3f43992adb6e598 /src
parent0aa0d6ffbe9bf02c3179b7cb2b978d1896655e05 (diff)
session: flag instead of state for filtering ntf
Avoid situations when notifications are delayed for long enough for transports to start closing/cleaning up. Type: fix Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: Id35b0099adb5242108154a5e19d5ee15e6ca0058
Diffstat (limited to 'src')
-rw-r--r--src/vnet/session/session_input.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/vnet/session/session_input.c b/src/vnet/session/session_input.c
index e6868815158..9153f07070d 100644
--- a/src/vnet/session/session_input.c
+++ b/src/vnet/session/session_input.c
@@ -194,12 +194,12 @@ app_worker_flush_events_inline (app_worker_t *app_wrk, u32 thread_index,
break;
case SESSION_CTRL_EVT_DISCONNECTED:
s = session_get (evt->session_index, thread_index);
- if (s->session_state <= SESSION_STATE_TRANSPORT_CLOSING)
+ if (!(s->flags & SESSION_F_APP_CLOSED))
app->cb_fns.session_disconnect_callback (s);
break;
case SESSION_CTRL_EVT_RESET:
s = session_get (evt->session_index, thread_index);
- if (s->session_state <= SESSION_STATE_TRANSPORT_CLOSING)
+ if (!(s->flags & SESSION_F_APP_CLOSED))
app->cb_fns.session_reset_callback (s);
break;
case SESSION_CTRL_EVT_UNLISTEN_REPLY: