diff options
author | Florin Coras <fcoras@cisco.com> | 2020-04-19 22:41:55 +0000 |
---|---|---|
committer | Dave Barach <openvpp@barachs.net> | 2020-04-20 14:47:02 +0000 |
commit | da302e4fce1003a2fdd2ace7e1ae09987399092c (patch) | |
tree | f4a0e06d3bac80ffe2e1a4fd4fb0641033d3977c | |
parent | f49cf470c583507fa1b5b841887107071701ef5e (diff) |
session: avoid rx notifications on accepting sessions
Type: fix
Signed-off-by: Florin Coras <fcoras@cisco.com>
Change-Id: Iba37e528e968104c3ba9c8324438ba695ddddfd1
-rw-r--r-- | src/vnet/session/session.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/vnet/session/session.c b/src/vnet/session/session.c index a709302c8a7..027070436fd 100644 --- a/src/vnet/session/session.c +++ b/src/vnet/session/session.c @@ -624,6 +624,11 @@ session_enqueue_notify_inline (session_t * s) SESSION_EVT (SESSION_EVT_ENQ, s, svm_fifo_max_dequeue_prod (s->rx_fifo)); s->flags &= ~SESSION_F_RX_EVT; + + /* Application didn't confirm accept yet */ + if (PREDICT_FALSE (s->session_state == SESSION_STATE_ACCEPTING)) + return 0; + if (PREDICT_FALSE (app_worker_lock_and_send_event (app_wrk, s, SESSION_IO_EVT_RX))) return -1; |