13 Star 5 Fork 32

src-openEuler/gazelle

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
0117-fix-host_addr6-can-be-assigned-a-multicast-address.patch 864 Bytes
一键复制 编辑 原始数据 按行查看 历史
yinbin6 提交于 2024-01-20 14:40 . sync adpat dpdk 23.11
From 7c8d80e76f93029437f9a52f04c9d02b0d55dd78 Mon Sep 17 00:00:00 2001
From: zhengjiebing <zhengjiebing_yewu@cmss.chinamobile.com>
Date: Tue, 16 Jan 2024 23:52:23 +0800
Subject: [PATCH] fix host_addr6 can be assigned a multicast address
---
src/lstack/core/lstack_cfg.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/src/lstack/core/lstack_cfg.c b/src/lstack/core/lstack_cfg.c
index 87df790..5e30e89 100644
--- a/src/lstack/core/lstack_cfg.c
+++ b/src/lstack/core/lstack_cfg.c
@@ -250,6 +250,12 @@ static int32_t parse_host_addr6(void)
if (ip6addr_aton(value, &g_config_params.host_addr6) == 0) {
return -EINVAL;
}
+
+ if (ip6_addr_ismulticast(&g_config_params.host_addr6)) {
+ LSTACK_PRE_LOG(LSTACK_ERR, "cfg: host_addr6 cannot be a multicast address.");
+ return -EINVAL;
+ }
+
return 0;
}
--
2.33.0
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/src-openeuler/gazelle.git
git@gitee.com:src-openeuler/gazelle.git
src-openeuler
gazelle
gazelle
master

搜索帮助