aboutsummaryrefslogtreecommitdiff
path: root/src/netbase.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/netbase.cpp')
-rw-r--r--src/netbase.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/netbase.cpp b/src/netbase.cpp
index dec00e1eeb..7a87d125c2 100644
--- a/src/netbase.cpp
+++ b/src/netbase.cpp
@@ -983,7 +983,7 @@ std::vector<unsigned char> CNetAddr::GetGroup() const
nBits -= 8;
}
if (nBits > 0)
- vchRet.push_back(GetByte(15 - nStartByte) | ((1 << nBits) - 1));
+ vchRet.push_back(GetByte(15 - nStartByte) | ((1 << (8 - nBits)) - 1));
return vchRet;
}