diff options
author | Russ White <russ@riw.us> | 2023-03-21 15:12:01 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-21 15:12:01 +0100 |
commit | 2c50f65f1cd205de75c3235066e36bbf60cdf9d1 (patch) | |
tree | df8cc99008dfe0538a7d3a818bbf107c81dfa332 /bgpd | |
parent | Merge pull request #12816 from gpnaveen/stc_rte_err_msg (diff) | |
parent | yang, bgpd: Fix "aggregator-asn" to support asdot (diff) | |
download | frr-2c50f65f1cd205de75c3235066e36bbf60cdf9d1.tar.xz frr-2c50f65f1cd205de75c3235066e36bbf60cdf9d1.zip |
Merge pull request #12968 from pguibert6WIND/asn_aggregator_counter_prop
yang: Fix "aggregator-asn" to support asdot
Diffstat (limited to 'bgpd')
-rw-r--r-- | bgpd/bgp_routemap_nb_config.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/bgpd/bgp_routemap_nb_config.c b/bgpd/bgp_routemap_nb_config.c index 142bded6c..4db8dba2c 100644 --- a/bgpd/bgp_routemap_nb_config.c +++ b/bgpd/bgp_routemap_nb_config.c @@ -2628,8 +2628,18 @@ int lib_route_map_entry_set_action_rmap_set_action_aggregator_aggregator_asn_modify( struct nb_cb_modify_args *args) { + const char *asn; + enum match_type match; + switch (args->event) { case NB_EV_VALIDATE: + asn = yang_dnode_get_string(args->dnode, NULL); + if (!asn) + return NB_ERR_VALIDATION; + match = asn_str2asn_match(asn); + if (match == exact_match) + return NB_OK; + return NB_ERR_VALIDATION; case NB_EV_PREPARE: case NB_EV_ABORT: case NB_EV_APPLY: |