diff options
author | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2017-12-13 11:21:18 +0000 |
---|---|---|
committer | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2017-12-18 15:15:54 +0000 |
commit | b51dc5668714a88d79ddb410d0dcab1559a4bc98 (patch) | |
tree | 343b7443c8193c90eb83bcb96a9d16ae4d2f6e52 /src/cryptonote_protocol | |
parent | net_parse_helpers: fix regex error checking (diff) | |
download | monero-b51dc5668714a88d79ddb410d0dcab1559a4bc98.tar.xz |
use const refs in for loops for non tiny types
Diffstat (limited to 'src/cryptonote_protocol')
-rw-r--r-- | src/cryptonote_protocol/block_queue.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cryptonote_protocol/block_queue.cpp b/src/cryptonote_protocol/block_queue.cpp index 9e38ffbcb..3844d3751 100644 --- a/src/cryptonote_protocol/block_queue.cpp +++ b/src/cryptonote_protocol/block_queue.cpp @@ -385,7 +385,7 @@ float block_queue::get_speed(const boost::uuids::uuid &connection_id) const i->second = (i->second + span.rate) / 2; } float conn_rate = -1, best_rate = 0; - for (auto i: speeds) + for (const auto &i: speeds) { if (i.first == connection_id) conn_rate = i.second; |