summaryrefslogtreecommitdiff
path: root/lib/if.c
diff options
context:
space:
mode:
authorPhilippe Guibert <philippe.guibert@6wind.com>2018-08-22 09:19:04 +0200
committerPhilippe Guibert <philippe.guibert@6wind.com>2018-08-22 09:19:04 +0200
commit3d4c0b49dacb454dbcf4dc3b56f8ccd8bb5202e5 (patch)
tree31e9a6f19b54d7585e1d89507ec04babc89df6e8 /lib/if.c
parent5ab5e410d0ee14924e3a6d91336df176a4f06655 (diff)
lib: change vrf_is_mapped_on_netns API
The function handles not a vrf pointer instead of a vrf_id value. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Diffstat (limited to 'lib/if.c')
-rw-r--r--lib/if.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/if.c b/lib/if.c
index 6023624dc1..11c4f1b5dc 100644
--- a/lib/if.c
+++ b/lib/if.c
@@ -393,7 +393,8 @@ struct interface *if_get_by_name(const char *name, vrf_id_t vrf_id, int vty)
* this should not be considered as an update
* then create the new interface
*/
- if (ifp->vrf_id != vrf_id && vrf_is_mapped_on_netns(vrf_id))
+ if (ifp->vrf_id != vrf_id && vrf_is_mapped_on_netns(
+ vrf_lookup_by_id(vrf_id)))
return if_create(name, vrf_id);
/* If it came from the kernel
* or by way of zclient, believe it and update