Skip to content

Commit

Permalink
ripd: fix no ip rip split-horizon poisoned-reverse command
Browse files Browse the repository at this point in the history
`no ip rip split-horizon poisoned-reverse` will undo poisoned-reverse and set default behavior which is split-horizon.
By contrast, `no ip rip split-horizon` will undo interface's split-horizon behavior.

Signed-off-by: Shbinging <[email protected]>
  • Loading branch information
Shbinging committed Feb 25, 2025
1 parent f35de3f commit 6d9db37
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions ripd/rip_cli.c
Original file line number Diff line number Diff line change
Expand Up @@ -680,9 +680,10 @@ DEFPY_YANG (ip_rip_split_horizon,
"With poisoned-reverse\n")
{
const char *value;

if (no)
if (no && poisoned_reverse == NULL)
value = "disabled";
else if (no && poisoned_reverse)
value = "simple";
else if (poisoned_reverse)
value = "poison-reverse";
else
Expand Down

0 comments on commit 6d9db37

Please sign in to comment.