Closed idryzhov closed 3 years ago
You are correct, it shouldn't enter the node... Seems like something broke the return value of that function.
Maybe we should also improve the DEFUN
s to also not allow having multihop
and empty source
.
@rzalamena I did git blame and it looks like the code was retuning CMD_SUCCESS since the beginning of transition to northbound model.
Describe the bug
After executing an invalid command in bfd configuration mode, vtysh enters the peer configuration mode despite the error.
[x] Did you check if this is a duplicate issue? [x] Did you test it on the latest FRRouting/frr master branch?
To Reproduce
Expected behavior
vtysh should not enter the peer configuration mode. bfdd doesn't enter this mode, so vtysh and bfdd become out of sync.
Screenshots
Versions
Additional context
The problem is that
nb_cli_apply_changes
(nb_cli_classic_commit
) returns CMD_SUCCESS to vtysh, so it thinks that the command execution was successful. I'm not sure how to fix this properly, so I decided to file an issue.