提交 fb7cebb7 编写于 作者: G Gerhard Stenzel 提交者: Daniel Veillard

remove port filter when network device is detached

* src/qemu/qemu_driver.c: remove the port filter if the network device
  is detached via virDomainDetachDevice.
上级 e7c78b0a
......@@ -5284,6 +5284,17 @@ qemudDomainDetachNetDevice(virConnectPtr conn,
}
qemuDomainObjExitMonitorWithDriver(driver, vm);
if ((driver->macFilter) && (detach->ifname != NULL)) {
if ((errno = networkDisallowMacOnPort(conn,
driver,
detach->ifname,
detach->mac))) {
virReportSystemError(conn, errno,
_("failed to remove ebtables rule on '%s'"),
detach->ifname);
}
}
if (vm->def->nnets > 1) {
memmove(vm->def->nets + i,
vm->def->nets + i + 1,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册