1 Star 0 Fork 70

mds.lanruo/libvirt

forked from src-openEuler/libvirt 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
vmx-Require-networkName-for-bridged-and-custom-NICs.patch 1.37 KB
一键复制 编辑 原始数据 按行查看 历史
yezengruan 提交于 2022-11-25 19:41 . sync some bugfix patches from upstream
From 6620c7cc62f11f1eda32c4b1c8006c0fdafb1c59 Mon Sep 17 00:00:00 2001
From: jipengfei <[email protected]>
Date: Thu, 24 Nov 2022 17:19:05 +0800
Subject: [PATCH 18/23] vmx: Require networkName for bridged and custom NICs
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
cherry-pick from db0564b4d34fb94fe59f04a4e411374ec1b6fc19
Commit 70768cda9740 marked this particular config string optional, but
forgot that two of the interface types still require this name to
exist. Mark it as optional only if there is no connectionType.
Signed-off-by: Martin Kletzander <[email protected]>
Signed-off-by: jipengfei <[email protected]>
Reviewed-by: Reviewed-by: Ján Tomko <[email protected]>
---
src/vmx/vmx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/vmx/vmx.c b/src/vmx/vmx.c
index fbc8366f2b..5f2ada6630 100644
--- a/src/vmx/vmx.c
+++ b/src/vmx/vmx.c
@@ -2667,7 +2667,7 @@ virVMXParseEthernet(virConfPtr conf, int controller, virDomainNetDefPtr *def)
STRCASEEQ(connectionType, "bridged") ||
STRCASEEQ(connectionType, "custom")) {
if (virVMXGetConfigString(conf, networkName_name, &networkName,
- true) < 0)
+ connectionType == NULL) < 0)
goto cleanup;
if (!networkName)
--
2.27.0
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/mdslanruo/libvirt.git
[email protected]:mdslanruo/libvirt.git
mdslanruo
libvirt
libvirt
master

搜索帮助