1 Star 0 Fork 21

src-oepkgs-oE-rv/keepalived

forked from src-openEuler/keepalived 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
0006-vrrp-fix-checking-if-kernel-netlink-socket-is-open.patch 876 Bytes
一键复制 编辑 原始数据 按行查看 历史
Randy.Wang 提交于 2021-06-10 09:41 . add upstream patches
From 2f7fdfc1a45931753d77a17b1b67c6725a5f6784 Mon Sep 17 00:00:00 2001
From: Quentin Armitage <quentin@armitage.org.uk>
Date: Wed, 14 Oct 2020 16:17:08 +0100
Subject: [PATCH 380/691] vrrp: fix checking if kernel netlink socket is open
0 is a valid value for a file descriptor.
Signed-off-by: Quentin Armitage <quentin@armitage.org.uk>
---
keepalived/core/keepalived_netlink.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/keepalived/core/keepalived_netlink.c b/keepalived/core/keepalived_netlink.c
index 6ac26dc..3169013 100644
--- a/keepalived/core/keepalived_netlink.c
+++ b/keepalived/core/keepalived_netlink.c
@@ -2314,7 +2314,7 @@ kernel_netlink(thread_ref_t thread)
void
kernel_netlink_poll(void)
{
- if (!nl_kernel.fd)
+ if (nl_kernel.fd < 0)
return;
netlink_parse_info(netlink_broadcast_filter, &nl_kernel, NULL, true);
--
1.8.3.1
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/src-oepkgs-oe-rv/keepalived.git
git@gitee.com:src-oepkgs-oe-rv/keepalived.git
src-oepkgs-oe-rv
keepalived
keepalived
master

搜索帮助