summaryrefslogtreecommitdiffstats
path: root/src/plugins/lb
diff options
context:
space:
mode:
authorVladislav Grishenko <themiron@yandex-team.ru>2022-08-04 20:36:45 +0500
committerDamjan Marion <dmarion@0xa5.net>2024-03-05 18:48:28 +0000
commitfb9d1ac843884aca79873577b53f6254e7933478 (patch)
tree7848ba7c81826ceafd886cfbbfd76fa9c1bcf562 /src/plugins/lb
parent7ad751ba53a792cc6beaade1eb61d0bd9dc87ea5 (diff)
vnet: fix format of deleted sw interfaces
As similar 535364e90459566b603661c3dbe360c72f59ad71 is merged, printing possibly deleted interfaces by index only in all the rest cases. Type: improvement Signed-off-by: Vladislav Grishenko <themiron@yandex-team.ru> Change-Id: I4fa58b382c0279ff893523ba0188fdb9b09e10af
Diffstat (limited to 'src/plugins/lb')
-rw-r--r--src/plugins/lb/cli.c26
1 files changed, 12 insertions, 14 deletions
diff --git a/src/plugins/lb/cli.c b/src/plugins/lb/cli.c
index 31152cd01f4..afa73ef616c 100644
--- a/src/plugins/lb/cli.c
+++ b/src/plugins/lb/cli.c
@@ -447,24 +447,22 @@ lb_set_interface_nat_command_fn (vlib_main_t * vm,
{
if (lb_nat4_interface_add_del (*sw_if_index, is_del))
{
- error = clib_error_return(
- 0, "%s %U failed", is_del ? "del" : "add",
- format_vnet_sw_interface_name, vnm,
- vnet_get_sw_interface (vnm, *sw_if_index));
- goto done;
- }
- }
+ error = clib_error_return (
+ 0, "%s %U failed", is_del ? "del" : "add",
+ format_vnet_sw_if_index_name, vnm, *sw_if_index);
+ goto done;
+ }
+ }
else
{
if (lb_nat6_interface_add_del (*sw_if_index, is_del))
{
- error = clib_error_return(
- 0, "%s %U failed", is_del ? "del" : "add",
- format_vnet_sw_interface_name, vnm,
- vnet_get_sw_interface (vnm, *sw_if_index));
- goto done;
- }
- }
+ error = clib_error_return (
+ 0, "%s %U failed", is_del ? "del" : "add",
+ format_vnet_sw_if_index_name, vnm, *sw_if_index);
+ goto done;
+ }
+ }
}
done: