summaryrefslogtreecommitdiff
path: root/bgpd/bgp_routemap.c
diff options
context:
space:
mode:
Diffstat (limited to 'bgpd/bgp_routemap.c')
-rw-r--r--bgpd/bgp_routemap.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/bgpd/bgp_routemap.c b/bgpd/bgp_routemap.c
index 261b7d240c..bcdc193cab 100644
--- a/bgpd/bgp_routemap.c
+++ b/bgpd/bgp_routemap.c
@@ -1253,8 +1253,7 @@ route_set_evpn_gateway_ip(void *rule, const struct prefix *prefix, void *object)
/* Set gateway-ip value. */
path->attr->evpn_overlay.type = OVERLAY_INDEX_GATEWAY_IP;
- memcpy(&path->attr->evpn_overlay.gw_ip, &gw_ip->ip.addr,
- IPADDRSZ(gw_ip));
+ path->attr->evpn_overlay.gw_ip = *gw_ip;
return RMAP_OKAY;
}