| 59 | } |
| 60 | |
| 61 | int AddrInfo::GetBucketPosition(const uint256& nKey, bool fNew, int nBucket) const |
| 62 | { |
| 63 | uint64_t hash1 = (CHashWriter(SER_GETHASH, 0) << nKey << (fNew ? uint8_t{'N'} : uint8_t{'K'}) << nBucket << GetKey()).GetCheapHash(); |
| 64 | return hash1 % ADDRMAN_BUCKET_SIZE; |
| 65 | } |
| 66 | |
| 67 | bool AddrInfo::IsTerrible(int64_t nNow) const |
| 68 | { |
no test coverage detected