From: Daniel Lezcano Date: Mon, 17 Jan 2011 09:18:50 +0000 (+0100) Subject: set veth host's side always up X-Git-Tag: lxc-0.7.4-rc1~11 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6e35af2e3911b5e8dc6e9091391beb8adfe449c6;p=thirdparty%2Flxc.git set veth host's side always up We should always have the veth host's side up, otherwise if we omit the up flag in the configurationn, letting the container to configure its interface, the network will be never enabled as the host's side is not up. Signed-off-by: Daniel Lezcano --- diff --git a/src/lxc/conf.c b/src/lxc/conf.c index 2f66e769f..a1bce19ec 100644 --- a/src/lxc/conf.c +++ b/src/lxc/conf.c @@ -1406,13 +1406,10 @@ static int instanciate_veth(struct lxc_handler *handler, struct lxc_netdev *netd goto out_delete; } - if (netdev->flags & IFF_UP) { - err = lxc_device_up(veth1); - if (err) { - ERROR("failed to set %s up : %s", veth1, - strerror(-err)); - goto out_delete; - } + err = lxc_device_up(veth1); + if (err) { + ERROR("failed to set %s up : %s", veth1, strerror(-err)); + goto out_delete; } if (netdev->upscript) {