Skip to content

Commit 3d39042

Browse files
committed
p2p: remove torv2 in SetIP() and ADDR_TORV2_SIZE constant
1 parent cff5ec4 commit 3d39042

File tree

2 files changed

+1
-4
lines changed

2 files changed

+1
-4
lines changed

src/netaddress.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ void CNetAddr::SetIP(const CNetAddr& ipIn)
115115
assert(ipIn.m_addr.size() == ADDR_IPV6_SIZE);
116116
break;
117117
case NET_ONION:
118-
assert(ipIn.m_addr.size() == ADDR_TORV2_SIZE || ipIn.m_addr.size() == ADDR_TORV3_SIZE);
118+
assert(ipIn.m_addr.size() == ADDR_TORV3_SIZE);
119119
break;
120120
case NET_I2P:
121121
assert(ipIn.m_addr.size() == ADDR_I2P_SIZE);

src/netaddress.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,6 @@ static constexpr size_t ADDR_IPV4_SIZE = 4;
9797
/// Size of IPv6 address (in bytes).
9898
static constexpr size_t ADDR_IPV6_SIZE = 16;
9999

100-
/// Size of TORv2 address (in bytes).
101-
static constexpr size_t ADDR_TORV2_SIZE = 10;
102-
103100
/// Size of TORv3 address (in bytes). This is the length of just the address
104101
/// as used in BIP155, without the checksum and the version byte.
105102
static constexpr size_t ADDR_TORV3_SIZE = 32;

0 commit comments

Comments
 (0)