aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/bonding/cli.c
diff options
context:
space:
mode:
authorDave Barach <dave@barachs.net>2018-10-17 10:38:51 -0400
committerDamjan Marion <dmarion@me.com>2018-10-23 13:06:46 +0000
commitb7b929931a07fbb27b43d5cd105f366c3e29807e (patch)
tree438681c89738802dbb5d339715b96ea2c31bafb4 /src/vnet/bonding/cli.c
parentb9a4c445c1d4e9cdab476a8e1fb8a46ff0fc6080 (diff)
c11 safe string handling support
Change-Id: Ied34720ca5a6e6e717eea4e86003e854031b6eab Signed-off-by: Dave Barach <dave@barachs.net>
Diffstat (limited to 'src/vnet/bonding/cli.c')
-rw-r--r--src/vnet/bonding/cli.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/vnet/bonding/cli.c b/src/vnet/bonding/cli.c
index ae046e640db..14c52f70b0b 100644
--- a/src/vnet/bonding/cli.c
+++ b/src/vnet/bonding/cli.c
@@ -91,7 +91,7 @@ bond_dump_ifs (bond_interface_details_t ** out_bondifs)
/* *INDENT-OFF* */
pool_foreach (bif, bm->interfaces,
vec_add2(r_bondifs, bondif, 1);
- memset (bondif, 0, sizeof (*bondif));
+ clib_memset (bondif, 0, sizeof (*bondif));
bondif->sw_if_index = bif->sw_if_index;
hi = vnet_get_hw_interface (vnm, bif->hw_if_index);
clib_memcpy(bondif->interface_name, hi->name,
@@ -129,7 +129,7 @@ bond_dump_slave_ifs (slave_interface_details_t ** out_slaveifs,
vec_foreach (sw_if_index, bif->slaves)
{
vec_add2 (r_slaveifs, slaveif, 1);
- memset (slaveif, 0, sizeof (*slaveif));
+ clib_memset (slaveif, 0, sizeof (*slaveif));
sif = bond_get_slave_by_sw_if_index (*sw_if_index);
if (sif)
{
@@ -231,7 +231,7 @@ bond_delete_if (vlib_main_t * vm, u32 sw_if_index)
clib_bitmap_free (bif->port_number_bitmap);
hash_unset (bm->bond_by_sw_if_index, bif->sw_if_index);
- memset (bif, 0, sizeof (*bif));
+ clib_memset (bif, 0, sizeof (*bif));
pool_put (bm->interfaces, bif);
return 0;
@@ -264,7 +264,7 @@ bond_create_if (vlib_main_t * vm, bond_create_if_args_t * args)
return;
}
pool_get (bm->interfaces, bif);
- memset (bif, 0, sizeof (*bif));
+ clib_memset (bif, 0, sizeof (*bif));
bif->dev_instance = bif - bm->interfaces;
bif->lb = args->lb;
bif->mode = args->mode;
@@ -449,7 +449,7 @@ bond_enslave (vlib_main_t * vm, bond_enslave_args_t * args)
return;
}
pool_get (bm->neighbors, sif);
- memset (sif, 0, sizeof (*sif));
+ clib_memset (sif, 0, sizeof (*sif));
sw = pool_elt_at_index (im->sw_interfaces, args->slave);
sif->port_enabled = sw->flags & VNET_SW_INTERFACE_FLAG_ADMIN_UP;
sif->sw_if_index = sw->sw_if_index;