We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6915276 commit 6c1d38bCopy full SHA for 6c1d38b
query.go
@@ -187,7 +187,7 @@ func (q *query) recordPeerIsValuable(p peer.ID) {
187
// protect _too_ many peers.
188
commonPrefixLen := kb.CommonPrefixLen(q.dht.selfKey, kb.ConvertPeerID(p))
189
cmgr := q.dht.host.ConnManager()
190
- if commonPrefixLen < 2 {
+ if commonPrefixLen < usefulConnMgrProtectedBuckets {
191
cmgr.Protect(p, dhtUsefulTag)
192
} else {
193
cmgr.TagPeer(p, dhtUsefulTag, usefulConnMgrScore)
0 commit comments