aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJay Wang <jay.wang2@arm.com>2024-11-12 10:20:39 +0000
committerNeale Ranns <neale@graphiant.com>2024-11-21 20:53:36 +0000
commit030a5436da0a55f9344fb32df89336c3990e4d28 (patch)
treec6e1cb390e80d1ec7be7f00a12717dab6ee9d840
parentff36307b5b9ce6e3d1d56aff8b6c6097ab1e0b6d (diff)
fib: fix `show ip fib memory` output error
Put `memory` before `mem` when parsing `show ip fib` CLI command to avoid the following annoying output error. vpp# show ip fib memory ipv4-VRF:0 mtrie:343808 hash:4687 totals: mtrie:343808 hash:4687 all:348495 unknown input `ory' Type: fix Signed-off-by: Jay Wang <jay.wang2@arm.com> Change-Id: I5f990243309d6e6ea339e8442f5e68ae90a98814
-rw-r--r--src/vnet/fib/ip4_fib.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/vnet/fib/ip4_fib.c b/src/vnet/fib/ip4_fib.c
index 23f70a770bf..b1198564754 100644
--- a/src/vnet/fib/ip4_fib.c
+++ b/src/vnet/fib/ip4_fib.c
@@ -354,8 +354,7 @@ ip4_show_fib (vlib_main_t * vm,
else if (unformat (input, "mtrie"))
mtrie = 1;
- else if (unformat (input, "mem") ||
- unformat (input, "memory"))
+ else if (unformat (input, "memory") || unformat (input, "mem"))
memory = 1;
else if (unformat (input, "%U/%d",
@@ -620,7 +619,7 @@ ip4_show_fib (vlib_main_t * vm,
?*/
VLIB_CLI_COMMAND (ip4_show_fib_command, static) = {
.path = "show ip fib",
- .short_help = "show ip fib [summary] [table <table-id>] [index <fib-id>] [<ip4-addr>[/<mask>]] [mtrie] [detail]",
+ .short_help = "show ip fib [summary] [table <table-id>] [index <fib-id>] [<ip4-addr>[/<mask>]] [mtrie] [detail] [memory]",
.function = ip4_show_fib,
};