summaryrefslogtreecommitdiff
path: root/node/Topology.hpp
diff options
context:
space:
mode:
authorAdam Ierymenko <adam.ierymenko@gmail.com>2015-10-30 13:39:28 -0700
committerAdam Ierymenko <adam.ierymenko@gmail.com>2015-10-30 13:39:28 -0700
commit377ccff600859da2d0e7ecd65a38953bd471d04d (patch)
tree30d9190e4e5fc4bc5c432fbecbbda9c2961b9f4b /node/Topology.hpp
parentf974517f64aac6b527fefa8f3b30088b804d2ae2 (diff)
downloadinfinitytier-377ccff600859da2d0e7ecd65a38953bd471d04d.tar.gz
infinitytier-377ccff600859da2d0e7ecd65a38953bd471d04d.zip
getPeer() had a small potential to be unsafe.
Diffstat (limited to 'node/Topology.hpp')
-rw-r--r--node/Topology.hpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/node/Topology.hpp b/node/Topology.hpp
index b9f063c8..d6f453ac 100644
--- a/node/Topology.hpp
+++ b/node/Topology.hpp
@@ -87,7 +87,7 @@ public:
inline SharedPtr<Peer> getPeerNoCache(const Address &zta,const uint64_t now)
{
Mutex::Lock _l(_lock);
- const SharedPtr<Peer> *ap = _peers.get(zta);
+ const SharedPtr<Peer> *const ap = _peers.get(zta);
if (ap) {
(*ap)->use(now);
return *ap;