summaryrefslogtreecommitdiffstats
path: root/src/vnet/lisp-cp/control.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/vnet/lisp-cp/control.c')
-rw-r--r--src/vnet/lisp-cp/control.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/vnet/lisp-cp/control.c b/src/vnet/lisp-cp/control.c
index e4015c76fce..09f5c0a652d 100644
--- a/src/vnet/lisp-cp/control.c
+++ b/src/vnet/lisp-cp/control.c
@@ -134,13 +134,15 @@ ip_address_to_fib_prefix (const ip_address_t * addr, fib_prefix_t * prefix)
prefix->fp_len = 32;
prefix->fp_proto = FIB_PROTOCOL_IP4;
clib_memset (&prefix->fp_addr.pad, 0, sizeof (prefix->fp_addr.pad));
- memcpy (&prefix->fp_addr.ip4, &addr->ip, sizeof (prefix->fp_addr.ip4));
+ memcpy (&prefix->fp_addr.ip4, &addr->ip.ip4,
+ sizeof (prefix->fp_addr.ip4));
}
else
{
prefix->fp_len = 128;
prefix->fp_proto = FIB_PROTOCOL_IP6;
- memcpy (&prefix->fp_addr.ip6, &addr->ip, sizeof (prefix->fp_addr.ip6));
+ memcpy (&prefix->fp_addr.ip6, &addr->ip.ip6,
+ sizeof (prefix->fp_addr.ip6));
}
prefix->___fp___pad = 0;
}