From f11e98eca3c4b4e3c91c826329018e848bcb9fc6 Mon Sep 17 00:00:00 2001 From: Philippe Guibert Date: Mon, 11 Feb 2019 15:46:48 +0100 Subject: *: change if_lookup_by_name() api with vrf the vrf_id parameter is replaced by struct vrf * parameter. this impacts most of the daemons that look for an interface based on the name and the vrf identifier. Also, it fixes 2 lookup calls in zebra and sharpd, where the vrf_id was ignored until now. Signed-off-by: Philippe Guibert --- zebra/interface.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'zebra/interface.c') diff --git a/zebra/interface.c b/zebra/interface.c index 13582008a7..6939c8c61f 100644 --- a/zebra/interface.c +++ b/zebra/interface.c @@ -1653,7 +1653,8 @@ DEFUN (show_interface_name_vrf, VRF_GET_ID(vrf_id, argv[idx_name]->arg, false); /* Specified interface print. */ - ifp = if_lookup_by_name(argv[idx_ifname]->arg, vrf_id); + ifp = if_lookup_by_name(argv[idx_ifname]->arg, + vrf_lookup_by_id(vrf_id)); if (ifp == NULL) { vty_out(vty, "%% Can't find interface %s\n", argv[idx_ifname]->arg); @@ -1683,7 +1684,7 @@ DEFUN (show_interface_name_vrf_all, /* All interface print. */ RB_FOREACH (vrf, vrf_name_head, &vrfs_by_name) { /* Specified interface print. */ - ifp = if_lookup_by_name(argv[idx_ifname]->arg, vrf->vrf_id); + ifp = if_lookup_by_name(argv[idx_ifname]->arg, vrf); if (ifp) { if_dump_vty(vty, ifp); found++; -- cgit v1.2.3