diff options
author | anlan_cs <vic.lan@pica8.com> | 2022-04-01 08:22:24 +0200 |
---|---|---|
committer | anlan_cs <vic.lan@pica8.com> | 2022-04-01 08:51:36 +0200 |
commit | e2d3f9166d06d9d32a2e83633eddeb3524de32bd (patch) | |
tree | 800979c34afc1c2005ce3db750be8b2e23af76e9 /bgpd/bgp_evpn_mh.c | |
parent | Merge pull request #10838 from ton31337/feature/bgpd_callbacks_for_start_end_... (diff) | |
download | frr-e2d3f9166d06d9d32a2e83633eddeb3524de32bd.tar.xz frr-e2d3f9166d06d9d32a2e83633eddeb3524de32bd.zip |
bgpd: use "assert" for one check on evpn-mh
"no ead-es-route-target export RT":
Since existance is already checked in `bgp_evpn_ead_es_rt_cmd`
with `bgp_evpn_rt_matches_existing()`, there MUST be a deleting
node in evpn's `bgp_mh_info->ead_es_export_rtl` list.
Just modify the check for deleting node to an `assert`.
Signed-off-by: anlan_cs <vic.lan@pica8.com>
Diffstat (limited to 'bgpd/bgp_evpn_mh.c')
-rw-r--r-- | bgpd/bgp_evpn_mh.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/bgpd/bgp_evpn_mh.c b/bgpd/bgp_evpn_mh.c index ed3716f60..d73186979 100644 --- a/bgpd/bgp_evpn_mh.c +++ b/bgpd/bgp_evpn_mh.c @@ -1273,9 +1273,9 @@ void bgp_evpn_mh_config_ead_export_rt(struct bgp *bgp, } } - if (node_to_del) - list_delete_node(bgp_mh_info->ead_es_export_rtl, - node_to_del); + assert(node_to_del); + list_delete_node(bgp_mh_info->ead_es_export_rtl, + node_to_del); } } else { listnode_add_sort(bgp_mh_info->ead_es_export_rtl, ecomcfg); |