*: fix up DEFUNs without install_element calls

These now generate warnings which will break the build with -Werror.

Note this may have enabled commands that should be disabled, or the
other way around...

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
This commit is contained in:
David Lamparter 2016-12-05 20:28:24 +01:00
parent 7ddcfca4fb
commit d7d73ffc8f
10 changed files with 19 additions and 34 deletions

View File

@ -11379,6 +11379,7 @@ community_list_vty (void)
/* Community-list. */ /* Community-list. */
install_element (CONFIG_NODE, &ip_community_list_standard_cmd); install_element (CONFIG_NODE, &ip_community_list_standard_cmd);
install_element (CONFIG_NODE, &ip_community_list_expanded_all_cmd);
install_element (CONFIG_NODE, &no_ip_community_list_standard_all_cmd); install_element (CONFIG_NODE, &no_ip_community_list_standard_all_cmd);
install_element (CONFIG_NODE, &no_ip_community_list_expanded_all_cmd); install_element (CONFIG_NODE, &no_ip_community_list_expanded_all_cmd);
install_element (VIEW_NODE, &show_ip_community_list_cmd); install_element (VIEW_NODE, &show_ip_community_list_cmd);

View File

@ -2069,21 +2069,6 @@ DEFUN (config_log_syslog,
} }
} }
DEFUN_DEPRECATED (config_log_syslog_facility,
config_log_syslog_facility_cmd,
"log syslog facility (kern|user|mail|daemon|auth|syslog|lpr|news|uucp|cron|local0|local1|local2|local3|local4|local5|local6|local7)",
"Logging control\n"
"Logging goes to syslog\n"
"(Deprecated) Facility parameter for syslog messages\n"
LOG_FACILITY_DESC)
{
int facility = facility_match(argv[3]->arg);
zlog_set_level (NULL, ZLOG_DEST_SYSLOG, zlog_default->default_lvl);
zlog_default->facility = facility;
return CMD_SUCCESS;
}
DEFUN (no_config_log_syslog, DEFUN (no_config_log_syslog,
no_config_log_syslog_cmd, no_config_log_syslog_cmd,
"no log syslog [<kern|user|mail|daemon|auth|syslog|lpr|news|uucp|cron|local0|local1|local2|local3|local4|local5|local6|local7>] [<emergencies|alerts|critical|errors|warnings|notifications|informational|debugging>]", "no log syslog [<kern|user|mail|daemon|auth|syslog|lpr|news|uucp|cron|local0|local1|local2|local3|local4|local5|local6|local7>] [<emergencies|alerts|critical|errors|warnings|notifications|informational|debugging>]",

View File

@ -838,6 +838,7 @@ if_cmd_init (void)
install_element (INTERFACE_NODE, &no_interface_desc_cmd); install_element (INTERFACE_NODE, &no_interface_desc_cmd);
} }
#if 0
/* For debug purpose. */ /* For debug purpose. */
DEFUN (show_address, DEFUN (show_address,
show_address_cmd, show_address_cmd,
@ -907,6 +908,7 @@ DEFUN (show_address_vrf_all,
} }
return CMD_SUCCESS; return CMD_SUCCESS;
} }
#endif
/* Allocate connected structure. */ /* Allocate connected structure. */
struct connected * struct connected *

View File

@ -913,6 +913,7 @@ void
ospf6_neighbor_init (void) ospf6_neighbor_init (void)
{ {
install_element (VIEW_NODE, &show_ipv6_ospf6_neighbor_cmd); install_element (VIEW_NODE, &show_ipv6_ospf6_neighbor_cmd);
install_element (VIEW_NODE, &show_ipv6_ospf6_neighbor_one_cmd);
} }
DEFUN (debug_ospf6_neighbor, DEFUN (debug_ospf6_neighbor,

View File

@ -622,6 +622,7 @@ DEFUN (no_ospf6_distance_ospf6,
return CMD_SUCCESS; return CMD_SUCCESS;
} }
#if 0
DEFUN (ospf6_distance_source, DEFUN (ospf6_distance_source,
ospf6_distance_source_cmd, ospf6_distance_source_cmd,
"distance (1-255) X:X::X:X/M [WORD]", "distance (1-255) X:X::X:X/M [WORD]",
@ -652,6 +653,7 @@ DEFUN (no_ospf6_distance_source,
return CMD_SUCCESS; return CMD_SUCCESS;
} }
#endif
DEFUN (ospf6_interface_area, DEFUN (ospf6_interface_area,
ospf6_interface_area_cmd, ospf6_interface_area_cmd,
@ -833,6 +835,7 @@ DEFUN (no_ospf6_stub_router_admin,
return CMD_SUCCESS; return CMD_SUCCESS;
} }
#if 0
DEFUN (ospf6_stub_router_startup, DEFUN (ospf6_stub_router_startup,
ospf6_stub_router_startup_cmd, ospf6_stub_router_startup_cmd,
"stub-router on-startup (5-86400)", "stub-router on-startup (5-86400)",
@ -878,6 +881,7 @@ DEFUN (no_ospf6_stub_router_shutdown,
{ {
return CMD_SUCCESS; return CMD_SUCCESS;
} }
#endif
static void static void
ospf6_show (struct vty *vty, struct ospf6 *o) ospf6_show (struct vty *vty, struct ospf6 *o)

View File

@ -1662,6 +1662,7 @@ ospf_router_info_register_vty (void)
install_element (OSPF_NODE, &pce_neighbor_cmd); install_element (OSPF_NODE, &pce_neighbor_cmd);
install_element (OSPF_NODE, &no_pce_neighbor_cmd); install_element (OSPF_NODE, &no_pce_neighbor_cmd);
install_element (OSPF_NODE, &pce_cap_flag_cmd); install_element (OSPF_NODE, &pce_cap_flag_cmd);
install_element (OSPF_NODE, &no_pce_cap_flag_cmd);
return; return;
} }

View File

@ -7800,6 +7800,7 @@ DEFUN (ospf_distance_ospf,
return CMD_SUCCESS; return CMD_SUCCESS;
} }
#if 0
DEFUN (ospf_distance_source, DEFUN (ospf_distance_source,
ospf_distance_source_cmd, ospf_distance_source_cmd,
"distance (1-255) A.B.C.D/M", "distance (1-255) A.B.C.D/M",
@ -7881,6 +7882,7 @@ DEFUN (no_ospf_distance_source_access_list,
return CMD_SUCCESS; return CMD_SUCCESS;
} }
#endif
DEFUN (ip_ospf_mtu_ignore, DEFUN (ip_ospf_mtu_ignore,
ip_ospf_mtu_ignore_addr_cmd, ip_ospf_mtu_ignore_addr_cmd,

View File

@ -2575,6 +2575,7 @@ DEFUN (no_ripng_timers,
return CMD_SUCCESS; return CMD_SUCCESS;
} }
#if 0
DEFUN (show_ipv6_protocols, DEFUN (show_ipv6_protocols,
show_ipv6_protocols_cmd, show_ipv6_protocols_cmd,
"show ipv6 protocols", "show ipv6 protocols",
@ -2601,6 +2602,7 @@ DEFUN (show_ipv6_protocols,
return CMD_SUCCESS; return CMD_SUCCESS;
} }
#endif
/* Please be carefull to use this command. */ /* Please be carefull to use this command. */
DEFUN (ripng_default_information_originate, DEFUN (ripng_default_information_originate,

View File

@ -1560,24 +1560,6 @@ DEFUNSH (VTYSH_BGPD,
return CMD_SUCCESS; return CMD_SUCCESS;
} }
DEFUNSH (VTYSH_ZEBRA,
vtysh_exit_zebra,
vtysh_exit_zebra_cmd,
"exit",
"Exit current mode and down to previous mode\n")
{
return vtysh_exit (vty);
}
DEFUNSH (VTYSH_ZEBRA,
vtysh_quit_zebra,
vtysh_quit_zebra_cmd,
"quit",
"Exit current mode and down to previous mode\n")
{
return vtysh_exit_zebra (self, vty, argc, argv);
}
DEFUNSH (VTYSH_RIPD, DEFUNSH (VTYSH_RIPD,
vtysh_exit_ripd, vtysh_exit_ripd,
vtysh_exit_ripd_cmd, vtysh_exit_ripd_cmd,
@ -3122,7 +3104,8 @@ vtysh_init_vty (void)
/* "exit" command. */ /* "exit" command. */
install_element (VIEW_NODE, &vtysh_exit_all_cmd); install_element (VIEW_NODE, &vtysh_exit_all_cmd);
install_element (CONFIG_NODE, &vtysh_exit_all_cmd); install_element (CONFIG_NODE, &vtysh_exit_all_cmd);
/* install_element (CONFIG_NODE, &vtysh_quit_all_cmd); */ install_element (VIEW_NODE, &vtysh_quit_all_cmd);
install_element (CONFIG_NODE, &vtysh_quit_all_cmd);
install_element (RIP_NODE, &vtysh_exit_ripd_cmd); install_element (RIP_NODE, &vtysh_exit_ripd_cmd);
install_element (RIP_NODE, &vtysh_quit_ripd_cmd); install_element (RIP_NODE, &vtysh_quit_ripd_cmd);
install_element (RIPNG_NODE, &vtysh_exit_ripngd_cmd); install_element (RIPNG_NODE, &vtysh_exit_ripngd_cmd);
@ -3226,6 +3209,8 @@ vtysh_init_vty (void)
install_element (INTERFACE_NODE, &vtysh_quit_interface_cmd); install_element (INTERFACE_NODE, &vtysh_quit_interface_cmd);
install_element (NS_NODE, &vtysh_end_all_cmd); install_element (NS_NODE, &vtysh_end_all_cmd);
install_element (CONFIG_NODE, &vtysh_ns_cmd);
install_element (NS_NODE, &vtysh_exit_ns_cmd); install_element (NS_NODE, &vtysh_exit_ns_cmd);
install_element (NS_NODE, &vtysh_quit_ns_cmd); install_element (NS_NODE, &vtysh_quit_ns_cmd);
@ -3255,6 +3240,7 @@ vtysh_init_vty (void)
#if defined(ENABLE_BGP_VNC) #if defined(ENABLE_BGP_VNC)
install_element (BGP_NODE, &vnc_defaults_cmd); install_element (BGP_NODE, &vnc_defaults_cmd);
install_element (BGP_NODE, &vnc_nve_group_cmd); install_element (BGP_NODE, &vnc_nve_group_cmd);
install_element (BGP_NODE, &vnc_l2_group_cmd);
#endif #endif
install_element (BGP_NODE, &address_family_ipv4_unicast_cmd); install_element (BGP_NODE, &address_family_ipv4_unicast_cmd);
install_element (BGP_NODE, &address_family_ipv4_multicast_cmd); install_element (BGP_NODE, &address_family_ipv4_multicast_cmd);

View File

@ -2909,6 +2909,7 @@ zebra_if_init (void)
install_element(LINK_PARAMS_NODE, &link_params_enable_cmd); install_element(LINK_PARAMS_NODE, &link_params_enable_cmd);
install_element(LINK_PARAMS_NODE, &no_link_params_enable_cmd); install_element(LINK_PARAMS_NODE, &no_link_params_enable_cmd);
install_element(LINK_PARAMS_NODE, &link_params_metric_cmd); install_element(LINK_PARAMS_NODE, &link_params_metric_cmd);
install_element(LINK_PARAMS_NODE, &no_link_params_metric_cmd);
install_element(LINK_PARAMS_NODE, &link_params_maxbw_cmd); install_element(LINK_PARAMS_NODE, &link_params_maxbw_cmd);
install_element(LINK_PARAMS_NODE, &link_params_max_rsv_bw_cmd); install_element(LINK_PARAMS_NODE, &link_params_max_rsv_bw_cmd);
install_element(LINK_PARAMS_NODE, &link_params_unrsv_bw_cmd); install_element(LINK_PARAMS_NODE, &link_params_unrsv_bw_cmd);