diff options
| author | Philippe Guibert <philippe.guibert@6wind.com> | 2018-08-27 17:00:18 +0200 |
|---|---|---|
| committer | Philippe Guibert <philippe.guibert@6wind.com> | 2018-08-27 17:03:22 +0200 |
| commit | 680c278fb8110b19873a4f4877878b1ea0eec2d3 (patch) | |
| tree | 5cc739d5a673331f0fcd2a41214098f542713f63 /zebra/interface.c | |
| parent | 95d8c3ce78cdd800f4c39d196e865c2ec9213f03 (diff) | |
zebra: when veth link is used across vrf, the link may not be good
This function is changed so that the interface index is searched across
the correct namespace.
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Diffstat (limited to 'zebra/interface.c')
| -rw-r--r-- | zebra/interface.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/zebra/interface.c b/zebra/interface.c index 763931d350..8558a8bd59 100644 --- a/zebra/interface.c +++ b/zebra/interface.c @@ -1002,13 +1002,14 @@ void if_refresh(struct interface *ifp) if_get_flags(ifp); } -void zebra_if_update_link(struct interface *ifp, ifindex_t link_ifindex) +void zebra_if_update_link(struct interface *ifp, ifindex_t link_ifindex, + ns_id_t ns_id) { struct zebra_if *zif; zif = (struct zebra_if *)ifp->info; zif->link_ifindex = link_ifindex; - zif->link = if_lookup_by_index_per_ns(zebra_ns_lookup(NS_DEFAULT), + zif->link = if_lookup_by_index_per_ns(zebra_ns_lookup(ns_id), link_ifindex); } |
