diff options
| -rw-r--r-- | bgpd/bgp_routemap.c | 4 | ||||
| -rw-r--r-- | bgpd/bgp_zebra.c | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/bgpd/bgp_routemap.c b/bgpd/bgp_routemap.c index 2f37367a8f..12a5e1d696 100644 --- a/bgpd/bgp_routemap.c +++ b/bgpd/bgp_routemap.c @@ -1688,10 +1688,10 @@ route_match_interface(void *rule, const struct prefix *prefix, void *object) path = object; - if (!path) + if (!path || !path->peer || !path->peer->bgp) return RMAP_NOMATCH; - ifp = if_lookup_by_name_all_vrf((char *)rule); + ifp = if_lookup_by_name((char *)rule, path->peer->bgp->vrf_id); if (ifp == NULL || ifp->ifindex != path->attr->nh_ifindex) return RMAP_NOMATCH; diff --git a/bgpd/bgp_zebra.c b/bgpd/bgp_zebra.c index 0249d53f02..0546c63869 100644 --- a/bgpd/bgp_zebra.c +++ b/bgpd/bgp_zebra.c @@ -3506,7 +3506,7 @@ void bgp_zebra_announce_default(struct bgp *bgp, struct nexthop *nh, /* create default route with interface <VRF> * with nexthop-vrf <VRF> */ - ifp = if_lookup_by_name_all_vrf(vrf->name); + ifp = if_lookup_by_name_vrf(vrf->name, vrf); if (!ifp) return; api_nh->vrf_id = nh->vrf_id; |
