]> git.proxmox.com Git - mirror_frr.git/commitdiff
zebra: add a few `const` in RNH code
authorDavid Lamparter <equinox@opensourcerouting.org>
Fri, 11 Mar 2022 11:47:46 +0000 (12:47 +0100)
committerDavid Lamparter <equinox@opensourcerouting.org>
Sun, 27 Mar 2022 12:57:22 +0000 (14:57 +0200)
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
zebra/zebra_rnh.c
zebra/zebra_rnh.h

index d439b1dbc519722f512b8e25b70ff120cb8efd77..7934a9d2066e34b7875413399eb78f430da85e15 100644 (file)
@@ -768,7 +768,7 @@ static void zebra_rnh_clear_nhc_flag(struct zebra_vrf *zvrf, afi_t afi,
  * of a particular VRF and address-family or a specific prefix.
  */
 void zebra_evaluate_rnh(struct zebra_vrf *zvrf, afi_t afi, int force,
-                       struct prefix *p, safi_t safi)
+                       const struct prefix *p, safi_t safi)
 {
        struct route_table *rnh_table;
        struct route_node *nrn;
@@ -803,7 +803,7 @@ void zebra_evaluate_rnh(struct zebra_vrf *zvrf, afi_t afi, int force,
 }
 
 void zebra_print_rnh_table(vrf_id_t vrfid, afi_t afi, safi_t safi,
-                          struct vty *vty, struct prefix *p)
+                          struct vty *vty, const struct prefix *p)
 {
        struct route_table *table;
        struct route_node *rn;
index 3991066d1b27f9d5dcb8e273f5d2ad3d50abac9d..70eda725c4a71d46d47aab9e876a2fa7939dc885 100644 (file)
@@ -44,9 +44,9 @@ extern void zebra_register_rnh_pseudowire(vrf_id_t, struct zebra_pw *, bool *);
 extern void zebra_deregister_rnh_pseudowire(vrf_id_t, struct zebra_pw *);
 extern void zebra_remove_rnh_client(struct rnh *rnh, struct zserv *client);
 extern void zebra_evaluate_rnh(struct zebra_vrf *zvrf, afi_t afi, int force,
-                              struct prefix *p, safi_t safi);
+                              const struct prefix *p, safi_t safi);
 extern void zebra_print_rnh_table(vrf_id_t vrfid, afi_t afi, safi_t safi,
-                                 struct vty *vty, struct prefix *p);
+                                 struct vty *vty, const struct prefix *p);
 
 extern int rnh_resolve_via_default(struct zebra_vrf *zvrf, int family);