We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c30f79d commit 73f71e1Copy full SHA for 73f71e1
src/net.h
@@ -258,8 +258,8 @@ class CConnman
258
259
void PushMessage(CNode* pnode, CSerializedNetMsg&& msg);
260
261
- template<typename Callable>
262
- void ForEachNode(Callable&& func)
+ using NodeFn = std::function<void(CNode*)>;
+ void ForEachNode(const NodeFn& func)
263
{
264
LOCK(cs_vNodes);
265
for (auto&& node : vNodes) {
@@ -268,8 +268,7 @@ class CConnman
268
}
269
};
270
271
272
- void ForEachNode(Callable&& func) const
+ void ForEachNode(const NodeFn& func) const
273
274
275
0 commit comments