bgpd: allow value 0 in aigp-metric setting

The value of 0 is accepted from peers, and can also be set by the
route-map "set aigp-metric igp-metric". For coonsistency, it should
be allowed in "set aigp-metric <value>" as well.

Signed-off-by: Enke Chen <enchen@paloaltonetworks.com>
(cherry picked from commit e07f38a43f)
This commit is contained in:
Enke Chen 2024-10-20 12:25:46 -07:00 committed by Mergify
parent 6b3836f78e
commit 5adaa9ec7f
2 changed files with 3 additions and 3 deletions

View File

@ -7136,7 +7136,7 @@ DEFUN_YANG (no_set_atomic_aggregate,
DEFPY_YANG (set_aigp_metric,
set_aigp_metric_cmd,
"set aigp-metric <igp-metric|(1-4294967295)>$aigp_metric",
"set aigp-metric <igp-metric|(0-4294967295)>$aigp_metric",
SET_STR
"BGP AIGP attribute (AIGP Metric TLV)\n"
"AIGP Metric value from IGP protocol\n"
@ -7156,7 +7156,7 @@ DEFPY_YANG (set_aigp_metric,
DEFPY_YANG (no_set_aigp_metric,
no_set_aigp_metric_cmd,
"no set aigp-metric [<igp-metric|(1-4294967295)>]",
"no set aigp-metric [<igp-metric|(0-4294967295)>]",
NO_STR
SET_STR
"BGP AIGP attribute (AIGP Metric TLV)\n"

View File

@ -320,7 +320,7 @@ Route Map Set Command
Set the maximum meric for the route.
.. clicmd:: set aigp-metric <igp-metric|(1-4294967295)>
.. clicmd:: set aigp-metric <igp-metric|(0-4294967295)>
Set the BGP attribute AIGP to a specific value. If ``igp-metric`` is specified,
then the value is taken from the IGP protocol, otherwise an arbitrary value.