From b94e4d24eac9456f9f011af8b97abf5725a7342a Mon Sep 17 00:00:00 2001 From: Roopa Prabhu Date: Tue, 8 Mar 2016 14:05:35 -0800 Subject: [PATCH] addons: vrf: fix incorrect check when checking for running vs configured slaves change 'or' to 'and'. Its valid for one of them to be null. This was causing vrf enslavement errors during bootup. This was a recent regression. Closes: CM-9757 Signed-off-by: Roopa Prabhu --- addons/vrf.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/vrf.py b/addons/vrf.py index 715849f..4310692 100644 --- a/addons/vrf.py +++ b/addons/vrf.py @@ -240,7 +240,7 @@ class vrf(moduleBase): def _add_vrf_slaves(self, ifaceobj): running_slaves = self.ipcmd.link_get_lowers(ifaceobj.name) config_slaves = ifaceobj.lowerifaces - if not config_slaves or not running_slaves: + if not config_slaves and not running_slaves: return add_slaves = set(config_slaves).difference(set(running_slaves)) del_slaves = set(running_slaves).difference(set(config_slaves))