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/dhcp/dhcp6_proxy_node.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/dhcp/dhcp6_proxy_node.c')
-rw-r--r-- | src/vnet/dhcp/dhcp6_proxy_node.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/vnet/dhcp/dhcp6_proxy_node.c b/src/vnet/dhcp/dhcp6_proxy_node.c index 7d157ad35a1..34454d6bd56 100644 --- a/src/vnet/dhcp/dhcp6_proxy_node.c +++ b/src/vnet/dhcp/dhcp6_proxy_node.c @@ -389,7 +389,7 @@ dhcpv6_proxy_to_server_input (vlib_main_t * vm, sizeof (*r1) + sizeof (*fwd_opt) + sizeof (*u1) + sizeof (*id1) + u1->length); - memset (ip1, 0, sizeof (*ip1)); + clib_memset (ip1, 0, sizeof (*ip1)); ip1->ip_version_traffic_class_and_flow_label = 0x60; ip1->payload_length = u1->length; ip1->protocol = PROTO_UDP; @@ -739,7 +739,7 @@ dhcpv6_proxy_to_client_input (vlib_main_t * vm, } len = clib_net_to_host_u16 (r0->length); - memset (ip1, 0, sizeof (*ip1)); + clib_memset (ip1, 0, sizeof (*ip1)); copy_ip6_address (&ip1->dst_address, &client_address); u1->checksum = 0; u1->src_port = clib_net_to_host_u16 (UDP_DST_PORT_dhcpv6_to_server); @@ -767,7 +767,7 @@ dhcpv6_proxy_to_client_input (vlib_main_t * vm, hi0 = vnet_get_sup_hw_interface (vnm, original_sw_if_index); ei0 = pool_elt_at_index (em->interfaces, hi0->hw_instance); clib_memcpy (mac0->src_address, ei0->address, sizeof (ei0->address)); - memset (&mac0->dst_address, 0xff, sizeof (mac0->dst_address)); + clib_memset (&mac0->dst_address, 0xff, sizeof (mac0->dst_address)); mac0->type = (si0->type == VNET_SW_INTERFACE_TYPE_SUB) ? clib_net_to_host_u16 (0x8100) : clib_net_to_host_u16 (0x86dd); |