diff options
Diffstat (limited to 'src/vnet/lisp-cp/lisp_api.c')
-rw-r--r-- | src/vnet/lisp-cp/lisp_api.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/vnet/lisp-cp/lisp_api.c b/src/vnet/lisp-cp/lisp_api.c index 3053611c611..cb2eb0d9171 100644 --- a/src/vnet/lisp-cp/lisp_api.c +++ b/src/vnet/lisp-cp/lisp_api.c @@ -130,6 +130,7 @@ vl_api_lisp_add_del_locator_set_t_handler (vl_api_lisp_add_del_locator_set_t * mp->locator_set_name[63] = 0; locator_name = format (0, "%s", mp->locator_set_name); + vec_terminate_c_string (locator_name); a->name = locator_name; a->is_add = mp->is_add; @@ -185,6 +186,7 @@ vl_api_lisp_add_del_locator_t_handler (vl_api_lisp_add_del_locator_t * mp) mp->locator_set_name[63] = 0; locator_name = format (0, "%s", mp->locator_set_name); + vec_terminate_c_string (locator_name); a->name = locator_name; a->locators = locators; @@ -252,6 +254,7 @@ vl_api_lisp_add_del_local_eid_t_handler (vl_api_lisp_add_del_local_eid_t * mp) mp->locator_set_name[63] = 0; name = format (0, "%s", mp->locator_set_name); + vec_terminate_c_string (name); p = hash_get_mem (lcm->locator_set_index_by_name, name); if (!p) { @@ -393,6 +396,7 @@ vl_api_lisp_pitr_set_locator_set_t_handler (vl_api_lisp_pitr_set_locator_set_t u8 *ls_name = 0; ls_name = format (0, "%s", mp->ls_name); + vec_terminate_c_string (ls_name); rv = vnet_lisp_pitr_set_locator_set (ls_name, mp->is_add); vec_free (ls_name); @@ -481,6 +485,7 @@ static void mp->locator_set_name[63] = 0; locator_set_name = format (0, "%s", mp->locator_set_name); + vec_terminate_c_string (locator_set_name); a->is_add = mp->is_add; a->locator_set_name = locator_set_name; @@ -627,6 +632,7 @@ vl_api_lisp_locator_dump_t_handler (vl_api_lisp_locator_dump_t * mp) /* make sure we get a proper C-string */ mp->ls_name[sizeof (mp->ls_name) - 1] = 0; ls_name = format (0, "%s", mp->ls_name); + vec_terminate_c_string (ls_name); p = hash_get_mem (lcm->locator_set_index_by_name, ls_name); if (!p) goto out; |