diff options
Diffstat (limited to 'src/vlibmemory/vlib_api.c')
-rw-r--r-- | src/vlibmemory/vlib_api.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/vlibmemory/vlib_api.c b/src/vlibmemory/vlib_api.c index c0066eb0b5c..9b6a34bb059 100644 --- a/src/vlibmemory/vlib_api.c +++ b/src/vlibmemory/vlib_api.c @@ -385,10 +385,16 @@ vl_api_clnt_process (vlib_main_t * vm, vlib_node_runtime_t * node, case SOCKET_READ_EVENT: for (i = 0; i < vec_len (event_data); i++) { + vl_api_registration_t *regp; + a = pool_elt_at_index (socket_main.process_args, event_data[i]); - vl_socket_process_api_msg (a->clib_file, a->regp, - (i8 *) a->data); - a = pool_elt_at_index (socket_main.process_args, event_data[i]); + regp = vl_socket_get_registration (a->reg_index); + if (regp) + { + vl_socket_process_api_msg (regp, (i8 *) a->data); + a = pool_elt_at_index (socket_main.process_args, + event_data[i]); + } vec_free (a->data); pool_put (socket_main.process_args, a); } |