diff options
author | Dave Barach <dave@barachs.net> | 2018-10-17 10:38:51 -0400 |
---|---|---|
committer | Damjan Marion <dmarion@me.com> | 2018-10-23 13:06:46 +0000 |
commit | b7b929931a07fbb27b43d5cd105f366c3e29807e (patch) | |
tree | 438681c89738802dbb5d339715b96ea2c31bafb4 /src/vnet/interface_api.c | |
parent | b9a4c445c1d4e9cdab476a8e1fb8a46ff0fc6080 (diff) |
c11 safe string handling support
Change-Id: Ied34720ca5a6e6e717eea4e86003e854031b6eab
Signed-off-by: Dave Barach <dave@barachs.net>
Diffstat (limited to 'src/vnet/interface_api.c')
-rw-r--r-- | src/vnet/interface_api.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/vnet/interface_api.c b/src/vnet/interface_api.c index 644babef894..c27f3e87975 100644 --- a/src/vnet/interface_api.c +++ b/src/vnet/interface_api.c @@ -194,7 +194,7 @@ send_sw_interface_details (vpe_api_main_t * am, vnet_get_sup_hw_interface (am->vnet_main, swif->sw_if_index); vl_api_sw_interface_details_t *mp = vl_msg_api_alloc (sizeof (*mp)); - memset (mp, 0, sizeof (*mp)); + clib_memset (mp, 0, sizeof (*mp)); mp->_vl_msg_id = ntohs (VL_API_SW_INTERFACE_DETAILS); mp->sw_if_index = ntohl (swif->sw_if_index); mp->sup_sw_if_index = ntohl (swif->sup_sw_if_index); @@ -268,7 +268,7 @@ send_sw_interface_details (vpe_api_main_t * am, u16 outer_tag = 0; u16 b_vlanid = 0; u32 i_sid = 0; - memset (ð_hdr, 0, sizeof (eth_hdr)); + clib_memset (ð_hdr, 0, sizeof (eth_hdr)); if (!l2pbb_get (am->vlib_main, am->vnet_main, swif->sw_if_index, &vtr_op, &outer_tag, ð_hdr, &b_vlanid, &i_sid)) @@ -556,7 +556,7 @@ send_sw_interface_get_table_reply (vl_api_registration_t * reg, vl_api_sw_interface_get_table_reply_t *mp; mp = vl_msg_api_alloc (sizeof (*mp)); - memset (mp, 0, sizeof (*mp)); + clib_memset (mp, 0, sizeof (*mp)); mp->_vl_msg_id = ntohs (VL_API_SW_INTERFACE_GET_TABLE_REPLY); mp->context = context; mp->retval = htonl (retval); @@ -719,7 +719,7 @@ send_sw_interface_event (vpe_api_main_t * am, vnet_hw_interface_t *hi = vnet_get_sup_hw_interface (vnm, swif->sw_if_index); mp = vl_msg_api_alloc (sizeof (*mp)); - memset (mp, 0, sizeof (*mp)); + clib_memset (mp, 0, sizeof (*mp)); mp->_vl_msg_id = ntohs (VL_API_SW_INTERFACE_EVENT); mp->sw_if_index = ntohl (swif->sw_if_index); mp->client_index = reg->client_index; @@ -967,7 +967,7 @@ send_interface_rx_placement_details (vpe_api_main_t * am, { vl_api_sw_interface_rx_placement_details_t *mp; mp = vl_msg_api_alloc (sizeof (*mp)); - memset (mp, 0, sizeof (*mp)); + clib_memset (mp, 0, sizeof (*mp)); mp->_vl_msg_id = htons (VL_API_SW_INTERFACE_RX_PLACEMENT_DETAILS); mp->sw_if_index = htonl (sw_if_index); @@ -1127,7 +1127,7 @@ vl_api_create_vlan_subif_t_handler (vl_api_create_vlan_subif_t * mp) goto out; } - memset (&template, 0, sizeof (template)); + clib_memset (&template, 0, sizeof (template)); template.type = VNET_SW_INTERFACE_TYPE_SUB; template.sup_sw_if_index = hi->sw_if_index; template.sub.id = id; @@ -1207,7 +1207,7 @@ vl_api_create_subif_t_handler (vl_api_create_subif_t * mp) goto out; } - memset (&template, 0, sizeof (template)); + clib_memset (&template, 0, sizeof (template)); template.type = VNET_SW_INTERFACE_TYPE_SUB; template.sup_sw_if_index = sw_if_index; template.sub.id = sub_id; |