]> git.proxmox.com Git - mirror_frr.git/commitdiff
vrrpd: const vrrp_lookup()
authorQuentin Young <qlyoung@cumulusnetworks.com>
Wed, 11 Sep 2019 20:29:05 +0000 (20:29 +0000)
committerQuentin Young <qlyoung@cumulusnetworks.com>
Mon, 9 Dec 2019 19:39:18 +0000 (14:39 -0500)
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
vrrpd/vrrp.c
vrrpd/vrrp.h

index 1cdcaf88acbef5cf2d7b980059842770393abba1..a0d5a4170551a61c6eb902656fa856171768c640 100644 (file)
@@ -654,12 +654,12 @@ void vrrp_vrouter_destroy(struct vrrp_vrouter *vr)
        XFREE(MTYPE_VRRP_RTR, vr);
 }
 
-struct vrrp_vrouter *vrrp_lookup(struct interface *ifp, uint8_t vrid)
+struct vrrp_vrouter *vrrp_lookup(const struct interface *ifp, uint8_t vrid)
 {
        struct vrrp_vrouter vr;
 
        vr.vrid = vrid;
-       vr.ifp = ifp;
+       vr.ifp = (struct interface *)ifp;
 
        return hash_lookup(vrrp_vrouters_hash, &vr);
 }
index 9c1139837f2e7907bc6033d56ba9a13eaee46ac4..b1994c23f7d697c6457c3feedf9115cbe29fb732 100644 (file)
@@ -567,6 +567,6 @@ int vrrp_config_write_global(struct vty *vty);
 /*
  * Find VRRP Virtual Router by Virtual Router ID
  */
-struct vrrp_vrouter *vrrp_lookup(struct interface *ifp, uint8_t vrid);
+struct vrrp_vrouter *vrrp_lookup(const struct interface *ifp, uint8_t vrid);
 
 #endif /* __VRRP_H__ */