diff options
author | Florin Coras <fcoras@cisco.com> | 2017-08-16 19:55:49 -0700 |
---|---|---|
committer | Dave Wallace <dwallacelf@gmail.com> | 2017-08-29 18:53:11 +0000 |
commit | c87c91d8b0e85997debaf575f2e30cc2702edf25 (patch) | |
tree | 49ac104b68b3212559bf00e3744a842072631264 /src/vnet/session/session.c | |
parent | 78d5abea8584041b872def163c39464087eed9ef (diff) |
session: segment manager improvements
- cleanup connects segment manager even if first
- fix segment manager allocation for listen sessions
- improve handling of process private segments (mheaps/main heap)
- added segment manager cli
Change-Id: Ic2ca97c3622ab2286d5fb5772aeb57680e64f769
Signed-off-by: Florin Coras <fcoras@cisco.com>
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Diffstat (limited to 'src/vnet/session/session.c')
-rw-r--r-- | src/vnet/session/session.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/vnet/session/session.c b/src/vnet/session/session.c index 6fe990476e7..ee22ccbe0ad 100644 --- a/src/vnet/session/session.c +++ b/src/vnet/session/session.c @@ -457,7 +457,10 @@ stream_session_connect_notify (transport_connection_t * tc, u8 is_fail) /* Get the app's index from the handle we stored when opening connection * and the opaque (api_context for external apps) from transport session * index*/ - app = application_get (handle >> 32); + app = application_get_if_valid (handle >> 32); + if (!app) + return -1; + opaque = tc->s_index; if (!is_fail) @@ -562,9 +565,7 @@ stream_session_delete_notify (transport_connection_t * tc) /* App might've been removed already */ s = stream_session_get_if_valid (tc->s_index, tc->thread_index); if (!s) - { - return; - } + return; stream_session_delete (s); } |