diff options
| author | vivek <vivek@cumulusnetworks.com> | 2016-02-28 03:06:35 +0000 |
|---|---|---|
| committer | vivek <vivek@cumulusnetworks.com> | 2016-02-28 03:06:35 +0000 |
| commit | 53eadacfc09eb94067cbf8f8f469881df1094ef7 (patch) | |
| tree | 8a2223fc41e52aa03d65ea95b36d843cd2bc43ae /lib/if.c | |
| parent | 67cc8c5e5f3ad79f9fee6417071f4aea77726156 (diff) | |
Quagga: Fix interface move from VRF to default VRF
Ensure that during interface lookup (non-vty context), if the interface is
found in a different VRF, it is "moved" into the requested VRF.
Signed-off-by: Vivek Venkatraman <vivek@cumulusnetworks.com>
Ticket: CM-9579
Reviewed By: CCR-4194
Testing Done: Manual
Diffstat (limited to 'lib/if.c')
| -rw-r--r-- | lib/if.c | 10 |
1 files changed, 6 insertions, 4 deletions
@@ -479,10 +479,12 @@ if_get_by_name_len_vrf (const char *name, size_t namelen, vrf_id_t vrf_id, int v * from the kernel by way of zclient, believe it and update * the ifp accordingly. */ - if (vrf_id == VRF_DEFAULT) - return ifp; - if (vty) - return NULL; + if (vty) + { + if (vrf_id == VRF_DEFAULT) + return ifp; + return NULL; + } else { if_update_vrf (ifp, name, namelen, vrf_id); |
