aboutsummaryrefslogtreecommitdiff
path: root/src/netbase.h
diff options
context:
space:
mode:
authorRicardo M. Correia <rcorreia@wizy.org>2012-05-13 21:31:59 +0200
committerRicardo M. Correia <rcorreia@wizy.org>2012-05-13 21:42:54 +0200
commit4843b55fd167c54d86eb9e1f19525ed363cfe72d (patch)
tree81a74462fdd3fc20a25521a8634121ad0b1a445f /src/netbase.h
parent1653f97c8f3c37cd96e03cf397c31c5caf81af08 (diff)
Make CNetAddr::GetHash() return an unsigned val.
This prevents an undefined operation in main.cpp, when shifting the hash value left by 32 bits. Shifting a signed int left into the sign bit is undefined in C++11.
Diffstat (limited to 'src/netbase.h')
-rw-r--r--src/netbase.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/netbase.h b/src/netbase.h
index 514a1ae950..544a666866 100644
--- a/src/netbase.h
+++ b/src/netbase.h
@@ -66,7 +66,7 @@ class CNetAddr
std::string ToString() const;
std::string ToStringIP() const;
int GetByte(int n) const;
- int64 GetHash() const;
+ uint64 GetHash() const;
bool GetInAddr(struct in_addr* pipv4Addr) const;
std::vector<unsigned char> GetGroup() const;
int GetReachabilityFrom(const CNetAddr *paddrPartner = NULL) const;