summaryrefslogtreecommitdiffstats
path: root/src/vnet
diff options
context:
space:
mode:
Diffstat (limited to 'src/vnet')
-rw-r--r--src/vnet/lisp-gpe/lisp_gpe_sub_interface.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/vnet/lisp-gpe/lisp_gpe_sub_interface.c b/src/vnet/lisp-gpe/lisp_gpe_sub_interface.c
index 56f5263650d..0dfbc40d8e7 100644
--- a/src/vnet/lisp-gpe/lisp_gpe_sub_interface.c
+++ b/src/vnet/lisp-gpe/lisp_gpe_sub_interface.c
@@ -49,11 +49,11 @@ lisp_gpe_sub_interface_db_find (const ip_address_t * lrloc, u32 vni)
{
uword *p;
- lisp_gpe_sub_interface_key_t key = {
- .local_rloc = *lrloc,
- .vni = clib_host_to_net_u32 (vni),
- };
+ lisp_gpe_sub_interface_key_t key;
+ memset (&key, 0, sizeof (key));
+ ip_address_copy (&key.local_rloc, lrloc);
+ key.vni = clib_host_to_net_u32 (vni);
p = hash_get_mem (lisp_gpe_sub_interfaces, &key);
if (NULL == p)
@@ -66,16 +66,16 @@ static void
lisp_gpe_sub_interface_db_insert (const lisp_gpe_sub_interface_t * l3s)
{
hash_set_mem (lisp_gpe_sub_interfaces,
- &l3s->key, l3s - lisp_gpe_sub_interface_pool);
+ l3s->key, l3s - lisp_gpe_sub_interface_pool);
hash_set_mem (lisp_gpe_sub_interfaces_sw_if_index,
- &l3s->key, l3s->sw_if_index);
+ l3s->key, l3s->sw_if_index);
}
static void
lisp_gpe_sub_interface_db_remove (const lisp_gpe_sub_interface_t * l3s)
{
- hash_unset_mem (lisp_gpe_sub_interfaces, &l3s->key);
- hash_unset_mem (lisp_gpe_sub_interfaces_sw_if_index, &l3s->key);
+ hash_unset_mem (lisp_gpe_sub_interfaces, l3s->key);
+ hash_unset_mem (lisp_gpe_sub_interfaces_sw_if_index, l3s->key);
}
lisp_gpe_sub_interface_t *