From 056f71f24cefaf88f2a93714c6678c03ed5f1e0e Mon Sep 17 00:00:00 2001
From: zhangmeng <775834166@qq.com>
Date: 星期五, 02 七月 2021 16:54:33 +0800
Subject: [PATCH] fixed to adapt gcc-5.4 & glibc-2.25
---
box/node_center.cpp | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/box/node_center.cpp b/box/node_center.cpp
index 77bfac1..76407a8 100644
--- a/box/node_center.cpp
+++ b/box/node_center.cpp
@@ -681,9 +681,15 @@
if (pos != sub_map.end()) {
auto &clients = pos->second;
for (auto &cli : clients) {
- if (Valid(cli.weak_node_)) {
- dests.insert(cli);
+ auto node = cli.weak_node_.lock();
+ if (node) {
+ if (node->state_.flag_ == kStateNormal)
+ dests.insert(cli);
}
+
+ // if (Valid(cli.weak_node_)) {
+ // dests.insert(cli);
+ // }
}
}
};
--
Gitblit v1.8.0