aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/session/session_api.c
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2018-02-14 08:04:31 -0800
committerDamjan Marion <dmarion.lists@gmail.com>2018-02-15 10:53:33 +0000
commit5fda7a3925be145f0c326d0aecc36d883cbcb2ee (patch)
tree399956ed3c583d5e8e6d1d75847a11148ee252e6 /src/vnet/session/session_api.c
parentfae4039ad2af251690e4cb79d5842a6e97029032 (diff)
session: avoid session handle conflict with vcl
Change-Id: I7f5a3b8d92ef07d60315bab6e560eba49ea07249 Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'src/vnet/session/session_api.c')
-rwxr-xr-xsrc/vnet/session/session_api.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/vnet/session/session_api.c b/src/vnet/session/session_api.c
index 11fa0faa738..f21701c3896 100755
--- a/src/vnet/session/session_api.c
+++ b/src/vnet/session/session_api.c
@@ -200,12 +200,23 @@ send_session_accept_callback (stream_session_t * s)
listener = listen_session_get (ls->listener_session_type,
ls->listener_index);
mp->listener_handle = listen_session_get_handle (listener);
+ mp->is_ip4 = session_type_is_ip4 (listener->session_type);
}
else
{
ll = application_get_local_listen_session (server,
ls->listener_index);
- mp->listener_handle = application_local_session_handle (ll);
+ if (ll->transport_listener_index != ~0)
+ {
+ listener = listen_session_get (ll->listener_session_type,
+ ll->transport_listener_index);
+ mp->listener_handle = listen_session_get_handle (listener);
+ }
+ else
+ {
+ mp->listener_handle = application_local_session_handle (ll);
+ }
+ mp->is_ip4 = session_type_is_ip4 (ll->listener_session_type);
}
mp->handle = application_local_session_handle (ls);
mp->port = ls->port;