summaryrefslogtreecommitdiff
path: root/zebra/zebra_evpn_neigh.c
diff options
context:
space:
mode:
authorMark Stapp <mjs.ietf@gmail.com>2022-02-08 14:35:43 -0500
committerGitHub <noreply@github.com>2022-02-08 14:35:43 -0500
commit45c402261a456624fba4313326d3c1dc2461a63c (patch)
tree11f1f01e5928cc477e47c9739b432cf6960e6f0d /zebra/zebra_evpn_neigh.c
parent6d30246ef11e1a249dfec0e6245da4968a5b5485 (diff)
parent60cda04dda2659b5bef684fe7b05ee0e501eb498 (diff)
Merge pull request #10530 from idryzhov/ipaddr-cmp
*: use ipaddr_cmp instead of memcmp
Diffstat (limited to 'zebra/zebra_evpn_neigh.c')
-rw-r--r--zebra/zebra_evpn_neigh.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/zebra/zebra_evpn_neigh.c b/zebra/zebra_evpn_neigh.c
index 7299391ef6..c3218d0f9a 100644
--- a/zebra/zebra_evpn_neigh.c
+++ b/zebra/zebra_evpn_neigh.c
@@ -72,7 +72,7 @@ static bool neigh_cmp(const void *p1, const void *p2)
if (n1 == NULL || n2 == NULL)
return false;
- return (memcmp(&n1->ip, &n2->ip, sizeof(struct ipaddr)) == 0);
+ return ipaddr_cmp(&n1->ip, &n2->ip) == 0;
}
int neigh_list_cmp(void *p1, void *p2)
@@ -80,7 +80,7 @@ int neigh_list_cmp(void *p1, void *p2)
const struct zebra_neigh *n1 = p1;
const struct zebra_neigh *n2 = p2;
- return memcmp(&n1->ip, &n2->ip, sizeof(struct ipaddr));
+ return ipaddr_cmp(&n1->ip, &n2->ip);
}
struct hash *zebra_neigh_db_create(const char *desc)