diff --git a/doc/user/pathd.rst b/doc/user/pathd.rst index ec107fbe4725..a8cb4b353050 100644 --- a/doc/user/pathd.rst +++ b/doc/user/pathd.rst @@ -471,7 +471,7 @@ Configuration Commands Disable or start the definition of a PCC. -.. clicmd:: msd (1-32) +.. clicmd:: msd [(1-32)] Specify the maximum SID depth in a PCC definition. diff --git a/pathd/path_pcep_cli.c b/pathd/path_pcep_cli.c index 298dd74d23e9..f2269b082207 100644 --- a/pathd/path_pcep_cli.c +++ b/pathd/path_pcep_cli.c @@ -1026,7 +1026,7 @@ static int path_pcep_cli_pcc_pcc_msd(struct vty *vty, const char *msd_str, { if (reset) pcc_msd_configured_g = false; - else { + else if (msd_str) { pcc_msd_configured_g = true; PCEP_VTYSH_INT_ARG_CHECK(msd_str, msd, pcc_msd_g, 0, 33); } @@ -2043,7 +2043,7 @@ DEFPY(pcep_cli_no_pcc, DEFPY(pcep_cli_pcc_pcc_msd, pcep_cli_pcc_pcc_msd_cmd, - "[no] msd (1-32)", + "[no] msd [(1-32)]", NO_STR "PCC maximum SID depth \n" "PCC maximum SID depth value\n")