Skip to content

Commit fa1622d

Browse files
author
MarcoFalke
committed
refactor: Make node_id a const& in RemoveBlockRequest
This works around a valgrind false-positive.
1 parent 9a8e5ad commit fa1622d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/net_processing.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1155,7 +1155,7 @@ void PeerManagerImpl::RemoveBlockRequest(const uint256& hash, std::optional<Node
11551155
Assume(mapBlocksInFlight.count(hash) <= MAX_CMPCTBLOCKS_INFLIGHT_PER_BLOCK);
11561156

11571157
while (range.first != range.second) {
1158-
auto [node_id, list_it] = range.first->second;
1158+
const auto& [node_id, list_it]{range.first->second};
11591159

11601160
if (from_peer && *from_peer != node_id) {
11611161
range.first++;

0 commit comments

Comments
 (0)