conf: only try to delete veth when privileged

parent 54e9a0e1
...@@ -3019,7 +3019,7 @@ bool lxc_delete_network(struct lxc_handler *handler) ...@@ -3019,7 +3019,7 @@ bool lxc_delete_network(struct lxc_handler *handler)
/* Explicitly delete host veth device to prevent lingering /* Explicitly delete host veth device to prevent lingering
* devices. We had issues in LXD around this. * devices. We had issues in LXD around this.
*/ */
if (netdev->type == LXC_NET_VETH) { if (netdev->type == LXC_NET_VETH && !am_unpriv()) {
char *hostveth; char *hostveth;
if (netdev->priv.veth_attr.pair) { if (netdev->priv.veth_attr.pair) {
hostveth = netdev->priv.veth_attr.pair; hostveth = netdev->priv.veth_attr.pair;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment