From 4eb33ee55496043a4b973c23e86618dbcf6d80d9 Mon Sep 17 00:00:00 2001 From: Christian Brauner Date: Mon, 17 Jul 2017 13:34:20 +0200 Subject: [PATCH] confile: clear vlan id Signed-off-by: Christian Brauner --- src/lxc/confile.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/lxc/confile.c b/src/lxc/confile.c index 0597d8e3b..6a6f549c9 100644 --- a/src/lxc/confile.c +++ b/src/lxc/confile.c @@ -988,6 +988,11 @@ static int set_config_network_vlan_id(const char *key, const char *value, return -1; } + if (lxc_config_value_empty(value)) { + netdev->priv.vlan_attr.vid = 0; + return 0; + } + if (get_u16(&netdev->priv.vlan_attr.vid, value, 0)) return -1; -- 2.47.2