From fd9f0c0640fd02a26b96b4f9d3cbbffbb6544a84 Mon Sep 17 00:00:00 2001 From: Maria Matejka Date: Wed, 8 Apr 2020 22:25:15 +0200 Subject: Configuration strings are constant. This is merely a const propagation. There was no problem in there. --- proto/babel/babel.c | 4 ++-- proto/babel/babel.h | 4 ++-- proto/bgp/bgp.h | 4 ++-- proto/mrt/mrt.h | 2 +- proto/ospf/ospf.c | 4 ++-- proto/ospf/ospf.h | 4 ++-- proto/radv/packets.c | 4 ++-- proto/radv/radv.h | 2 +- proto/rip/rip.c | 4 ++-- proto/rip/rip.h | 4 ++-- 10 files changed, 18 insertions(+), 18 deletions(-) (limited to 'proto') diff --git a/proto/babel/babel.c b/proto/babel/babel.c index 177ff3a3..a915e8fa 100644 --- a/proto/babel/babel.c +++ b/proto/babel/babel.c @@ -1874,7 +1874,7 @@ babel_get_attr(eattr *a, byte *buf, int buflen UNUSED) } void -babel_show_interfaces(struct proto *P, char *iff) +babel_show_interfaces(struct proto *P, const char *iff) { struct babel_proto *p = (void *) P; struct babel_iface *ifa = NULL; @@ -1912,7 +1912,7 @@ babel_show_interfaces(struct proto *P, char *iff) } void -babel_show_neighbors(struct proto *P, char *iff) +babel_show_neighbors(struct proto *P, const char *iff) { struct babel_proto *p = (void *) P; struct babel_iface *ifa = NULL; diff --git a/proto/babel/babel.h b/proto/babel/babel.h index 14765c60..e075024c 100644 --- a/proto/babel/babel.h +++ b/proto/babel/babel.h @@ -368,8 +368,8 @@ void babel_handle_update(union babel_msg *msg, struct babel_iface *ifa); void babel_handle_route_request(union babel_msg *msg, struct babel_iface *ifa); void babel_handle_seqno_request(union babel_msg *msg, struct babel_iface *ifa); -void babel_show_interfaces(struct proto *P, char *iff); -void babel_show_neighbors(struct proto *P, char *iff); +void babel_show_interfaces(struct proto *P, const char *iff); +void babel_show_neighbors(struct proto *P, const char *iff); void babel_show_entries(struct proto *P); void babel_show_routes(struct proto *P); diff --git a/proto/bgp/bgp.h b/proto/bgp/bgp.h index 03b92bd8..dc63e13e 100644 --- a/proto/bgp/bgp.h +++ b/proto/bgp/bgp.h @@ -125,9 +125,9 @@ struct bgp_config { unsigned disable_after_error; /* Disable the protocol when error is detected */ u32 disable_after_cease; /* Disable it when cease is received, bitfield */ - char *password; /* Password used for MD5 authentication */ + const char *password; /* Password used for MD5 authentication */ net_addr *remote_range; /* Allowed neighbor range for dynamic BGP */ - char *dynamic_name; /* Name pattern for dynamic BGP */ + const char *dynamic_name; /* Name pattern for dynamic BGP */ int dynamic_name_digits; /* Minimum number of digits for dynamic names */ int check_link; /* Use iface link state for liveness detection */ int bfd; /* Use BFD for liveness detection */ diff --git a/proto/mrt/mrt.h b/proto/mrt/mrt.h index 4dfb1b19..4ff94c12 100644 --- a/proto/mrt/mrt.h +++ b/proto/mrt/mrt.h @@ -42,7 +42,7 @@ struct mrt_dump_data { const char *table_expr; struct rtable *table_ptr; const struct filter *filter; - char *filename; + const char *filename; }; struct mrt_peer_entry { diff --git a/proto/ospf/ospf.c b/proto/ospf/ospf.c index 63ff9e56..29610f4a 100644 --- a/proto/ospf/ospf.c +++ b/proto/ospf/ospf.c @@ -791,7 +791,7 @@ ospf_reconfigure(struct proto *P, struct proto_config *CF) void -ospf_sh_neigh(struct proto *P, char *iff) +ospf_sh_neigh(struct proto *P, const char *iff) { struct ospf_proto *p = (struct ospf_proto *) P; struct ospf_iface *ifa = NULL; @@ -900,7 +900,7 @@ ospf_sh(struct proto *P) } void -ospf_sh_iface(struct proto *P, char *iff) +ospf_sh_iface(struct proto *P, const char *iff) { struct ospf_proto *p = (struct ospf_proto *) P; struct ospf_iface *ifa = NULL; diff --git a/proto/ospf/ospf.h b/proto/ospf/ospf.h index 8318ee95..d0286f72 100644 --- a/proto/ospf/ospf.h +++ b/proto/ospf/ospf.h @@ -990,9 +990,9 @@ static inline int oa_is_nssa(struct ospf_area *oa) void ospf_stop_gr_recovery(struct ospf_proto *p); -void ospf_sh_neigh(struct proto *P, char *iff); +void ospf_sh_neigh(struct proto *P, const char *iff); void ospf_sh(struct proto *P); -void ospf_sh_iface(struct proto *P, char *iff); +void ospf_sh_iface(struct proto *P, const char *iff); void ospf_sh_state(struct proto *P, int verbose, int reachable); void ospf_sh_lsadb(struct lsadb_show_data *ld); diff --git a/proto/radv/packets.c b/proto/radv/packets.c index 3139d321..5cd8b2de 100644 --- a/proto/radv/packets.c +++ b/proto/radv/packets.c @@ -173,8 +173,8 @@ radv_process_domain(struct radv_dnssl_config *cf) { /* Format of domain in search list is