mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-05-30 22:25:41 +00:00
bgpd: labeled-unicast issue changing from no import-check to using import-check
Problem seen in testing import-check using labeled-unicast address-family. When transitioning from "no bgp network import-check" to "bgp network import-check", previously installed networks were not removed. This fix resolves this. Ticket: CM-16512 Signed-off-by: Don Slice <dslice@cumulusnetworks.com>
This commit is contained in:
parent
cf4e348abb
commit
4dfee0ce4e
@ -3901,10 +3901,9 @@ bgp_static_update (struct bgp *bgp, struct prefix *p,
|
|||||||
|
|
||||||
/* Nexthop reachability check. */
|
/* Nexthop reachability check. */
|
||||||
if (bgp_flag_check (bgp, BGP_FLAG_IMPORT_CHECK) &&
|
if (bgp_flag_check (bgp, BGP_FLAG_IMPORT_CHECK) &&
|
||||||
safi == SAFI_UNICAST)
|
(safi == SAFI_UNICAST || safi == SAFI_LABELED_UNICAST))
|
||||||
{
|
{
|
||||||
if (bgp_find_or_add_nexthop (bgp, afi, ri, NULL, 0) &&
|
if (bgp_find_or_add_nexthop (bgp, afi, ri, NULL, 0))
|
||||||
safi == SAFI_UNICAST)
|
|
||||||
bgp_info_set_flag (rn, ri, BGP_INFO_VALID);
|
bgp_info_set_flag (rn, ri, BGP_INFO_VALID);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -3942,7 +3941,8 @@ bgp_static_update (struct bgp *bgp, struct prefix *p,
|
|||||||
new = info_make(ZEBRA_ROUTE_BGP, BGP_ROUTE_STATIC, 0, bgp->peer_self, attr_new,
|
new = info_make(ZEBRA_ROUTE_BGP, BGP_ROUTE_STATIC, 0, bgp->peer_self, attr_new,
|
||||||
rn);
|
rn);
|
||||||
/* Nexthop reachability check. */
|
/* Nexthop reachability check. */
|
||||||
if (bgp_flag_check (bgp, BGP_FLAG_IMPORT_CHECK))
|
if (bgp_flag_check (bgp, BGP_FLAG_IMPORT_CHECK) &&
|
||||||
|
(safi == SAFI_UNICAST || safi == SAFI_LABELED_UNICAST))
|
||||||
{
|
{
|
||||||
if (bgp_find_or_add_nexthop (bgp, afi, new, NULL, 0))
|
if (bgp_find_or_add_nexthop (bgp, afi, new, NULL, 0))
|
||||||
bgp_info_set_flag (rn, new, BGP_INFO_VALID);
|
bgp_info_set_flag (rn, new, BGP_INFO_VALID);
|
||||||
|
Loading…
Reference in New Issue
Block a user