Skip to content

Commit deddadb

Browse files
committed
Merge 5edef20 into merged_master (Bitcoin PR #19797)
2 parents ad13ce9 + 5edef20 commit deddadb

File tree

1 file changed

+0
-11
lines changed

1 file changed

+0
-11
lines changed

src/netaddress.cpp

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -270,17 +270,6 @@ bool CNetAddr::IsLocal() const
270270
*/
271271
bool CNetAddr::IsValid() const
272272
{
273-
// Cleanup 3-byte shifted addresses caused by garbage in size field
274-
// of addr messages from versions before 0.2.9 checksum.
275-
// Two consecutive addr messages look like this:
276-
// header20 vectorlen3 addr26 addr26 addr26 header20 vectorlen3 addr26 addr26 addr26...
277-
// so if the first length field is garbled, it reads the second batch
278-
// of addr misaligned by 3 bytes.
279-
if (IsIPv6() && memcmp(m_addr.data(), IPV4_IN_IPV6_PREFIX.data() + 3,
280-
sizeof(IPV4_IN_IPV6_PREFIX) - 3) == 0) {
281-
return false;
282-
}
283-
284273
// unspecified IPv6 address (::/128)
285274
unsigned char ipNone6[16] = {};
286275
if (IsIPv6() && memcmp(m_addr.data(), ipNone6, sizeof(ipNone6)) == 0) {

0 commit comments

Comments
 (0)