X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=src%2Fvnet%2Fbfd%2Fbfd_cli.c;h=4b5f75eb01bebe47c95ac714083e85390be740b7;hb=7c9fe920ce30efaef5a848ba346d0c7b53a77dd4;hp=33492ca85005ee79f9a2c6ab611cfa6004fe5d90;hpb=dcbea0b74b3485d3c60edb2bf73ee044a70483f1;p=vpp.git diff --git a/src/vnet/bfd/bfd_cli.c b/src/vnet/bfd/bfd_cli.c index 33492ca8500..4b5f75eb01b 100644 --- a/src/vnet/bfd/bfd_cli.c +++ b/src/vnet/bfd/bfd_cli.c @@ -170,7 +170,7 @@ show_bfd (vlib_main_t * vm, unformat_input_t * input, if (is_set) { vnet_sw_interface_t *sw_if = - vnet_get_sw_interface_safe (&vnet_main, sw_if_index); + vnet_get_sw_interface_or_null (&vnet_main, sw_if_index); vnet_hw_interface_t *hw_if = vnet_get_hw_interface (&vnet_main, sw_if->hw_if_index); u8 *s = format (NULL, "UDP echo source is: %v\n", hw_if->name); @@ -218,22 +218,6 @@ VLIB_CLI_COMMAND (show_bfd_command, static) = { }; /* *INDENT-ON* */ -static u8 * -format_vnet_api_errno (u8 * s, va_list * args) -{ - vnet_api_error_t api_error = va_arg (*args, vnet_api_error_t); -#define _(a, b, c) \ - case b: \ - s = format (s, "%s", c); \ - break; - switch (api_error) - { - foreach_vnet_api_error default:s = format (s, "UNKNOWN"); - break; - } - return s; -} - static clib_error_t * bfd_cli_key_add (vlib_main_t * vm, unformat_input_t * input, CLIB_UNUSED (vlib_cli_command_t * lmd))