]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
network: Fixes bug in macvlan mode selection 2957/head
authortomponline <thomas.parrott@canonical.com>
Mon, 29 Apr 2019 14:11:17 +0000 (15:11 +0100)
committertomponline <thomas.parrott@canonical.com>
Mon, 29 Apr 2019 14:11:17 +0000 (15:11 +0100)
Signed-off-by: tomponline <thomas.parrott@canonical.com>
src/lxc/confile_utils.c

index 50777c448190db68193ee230a9b08f5baa416d40..007a030e9ff434fca28534f4792afb37807ceb39 100644 (file)
@@ -474,7 +474,7 @@ char *lxc_macvlan_flag_to_mode(int mode)
        size_t i;
 
        for (i = 0; i < sizeof(macvlan_mode) / sizeof(macvlan_mode[0]); i++) {
-               if (macvlan_mode[i].mode == mode)
+               if (macvlan_mode[i].mode != mode)
                        continue;
 
                return macvlan_mode[i].name;