diff options
| author | Igor Ryzhov <iryzhov@nfware.com> | 2021-10-13 20:08:37 +0300 | 
|---|---|---|
| committer | Igor Ryzhov <iryzhov@nfware.com> | 2021-10-13 20:12:35 +0300 | 
| commit | 2560505196b924f5c447f6c1d493ed9b74a13108 (patch) | |
| tree | 515278e4362bf4f9c9418168df90a90b74946c20 /eigrpd/eigrp_cli.h | |
| parent | d7374bd3b1be5edfc20534ae5a301a0160c017bf (diff) | |
lib: northbound cli show/cmd functions must not modify data nodes
To ensure this, add a const modifier to functions' arguments. Would be
great do this initially and avoid this large code change, but better
late than never.
Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
Diffstat (limited to 'eigrpd/eigrp_cli.h')
| -rw-r--r-- | eigrpd/eigrp_cli.h | 47 | 
1 files changed, 29 insertions, 18 deletions
diff --git a/eigrpd/eigrp_cli.h b/eigrpd/eigrp_cli.h index c5f2fd8009..8b16dea39a 100644 --- a/eigrpd/eigrp_cli.h +++ b/eigrpd/eigrp_cli.h @@ -25,45 +25,56 @@  #define _EIGRP_CLI_H_  /*Prototypes*/ -extern void eigrp_cli_show_header(struct vty *vty, struct lyd_node *dnode, +extern void eigrp_cli_show_header(struct vty *vty, const struct lyd_node *dnode,  				  bool show_defaults); -extern void eigrp_cli_show_end_header(struct vty *vty, struct lyd_node *dnode); -extern void eigrp_cli_show_router_id(struct vty *vty, struct lyd_node *dnode, +extern void eigrp_cli_show_end_header(struct vty *vty, +				      const struct lyd_node *dnode); +extern void eigrp_cli_show_router_id(struct vty *vty, +				     const struct lyd_node *dnode,  				     bool show_defaults);  extern void eigrp_cli_show_passive_interface(struct vty *vty, -					     struct lyd_node *dnode, +					     const struct lyd_node *dnode,  					     bool show_defaults); -extern void eigrp_cli_show_active_time(struct vty *vty, struct lyd_node *dnode, +extern void eigrp_cli_show_active_time(struct vty *vty, +				       const struct lyd_node *dnode,  				       bool show_defaults); -extern void eigrp_cli_show_variance(struct vty *vty, struct lyd_node *dnode, +extern void eigrp_cli_show_variance(struct vty *vty, +				    const struct lyd_node *dnode,  				    bool show_defaults);  extern void eigrp_cli_show_maximum_paths(struct vty *vty, -					 struct lyd_node *dnode, +					 const struct lyd_node *dnode,  					 bool show_defaults); -extern void eigrp_cli_show_metrics(struct vty *vty, struct lyd_node *dnode, +extern void eigrp_cli_show_metrics(struct vty *vty, +				   const struct lyd_node *dnode,  				   bool show_defaults); -extern void eigrp_cli_show_network(struct vty *vty, struct lyd_node *dnode, +extern void eigrp_cli_show_network(struct vty *vty, +				   const struct lyd_node *dnode,  				   bool show_defaults); -extern void eigrp_cli_show_neighbor(struct vty *vty, struct lyd_node *dnode, +extern void eigrp_cli_show_neighbor(struct vty *vty, +				    const struct lyd_node *dnode,  				    bool show_defaults); -extern void eigrp_cli_show_redistribute(struct vty *vty, struct lyd_node *dnode, +extern void eigrp_cli_show_redistribute(struct vty *vty, +					const struct lyd_node *dnode,  					bool show_defaults); -extern void eigrp_cli_show_delay(struct vty *vty, struct lyd_node *dnode, +extern void eigrp_cli_show_delay(struct vty *vty, const struct lyd_node *dnode,  				 bool show_defaults); -extern void eigrp_cli_show_bandwidth(struct vty *vty, struct lyd_node *dnode, +extern void eigrp_cli_show_bandwidth(struct vty *vty, +				     const struct lyd_node *dnode,  				     bool show_defaults);  extern void eigrp_cli_show_hello_interval(struct vty *vty, -					  struct lyd_node *dnode, +					  const struct lyd_node *dnode,  					  bool show_defaults); -extern void eigrp_cli_show_hold_time(struct vty *vty, struct lyd_node *dnode, +extern void eigrp_cli_show_hold_time(struct vty *vty, +				     const struct lyd_node *dnode,  				     bool show_defaults);  extern void eigrp_cli_show_summarize_address(struct vty *vty, -					     struct lyd_node *dnode, +					     const struct lyd_node *dnode,  					     bool show_defaults);  extern void eigrp_cli_show_authentication(struct vty *vty, -					  struct lyd_node *dnode, +					  const struct lyd_node *dnode,  					  bool show_defaults); -extern void eigrp_cli_show_keychain(struct vty *vty, struct lyd_node *dnode, +extern void eigrp_cli_show_keychain(struct vty *vty, +				    const struct lyd_node *dnode,  				    bool show_defaults);  extern void eigrp_cli_init(void);  | 
