diff options
Diffstat (limited to 'bgpd/bgpd.c')
-rw-r--r-- | bgpd/bgpd.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/bgpd/bgpd.c b/bgpd/bgpd.c index a518137f3..895f36f99 100644 --- a/bgpd/bgpd.c +++ b/bgpd/bgpd.c @@ -4337,7 +4337,7 @@ bool bgp_path_attribute_discard(struct peer *peer, char *buf, size_t size) buf[0] = '\0'; - for (unsigned int i = 0; i < BGP_ATTR_MAX; i++) { + for (unsigned int i = 1; i <= BGP_ATTR_MAX; i++) { if (peer->discard_attrs[i]) snprintf(buf + strlen(buf), size - strlen(buf), "%s%d", (strlen(buf) > 0) ? " " : "", i); @@ -4357,7 +4357,7 @@ bool bgp_path_attribute_treat_as_withdraw(struct peer *peer, char *buf, buf[0] = '\0'; - for (unsigned int i = 0; i < BGP_ATTR_MAX; i++) { + for (unsigned int i = 1; i <= BGP_ATTR_MAX; i++) { if (peer->withdraw_attrs[i]) snprintf(buf + strlen(buf), size - strlen(buf), "%s%d", (strlen(buf) > 0) ? " " : "", i); |