diff --git a/bgpd/bgp_route.c b/bgpd/bgp_route.c index a3a8832bd6..54b2978880 100644 --- a/bgpd/bgp_route.c +++ b/bgpd/bgp_route.c @@ -8652,6 +8652,10 @@ void bgp_redistribute_add(struct bgp *bgp, struct prefix *p, route_map_result_t ret; struct bgp_redist *red; + if (CHECK_FLAG(bgp->flags, BGP_FLAG_DELETE_IN_PROGRESS) || + bgp->peer_self == NULL) + return; + /* Make default attribute. */ bgp_attr_default_set(&attr, bgp, BGP_ORIGIN_INCOMPLETE); /*