mirror of
https://github.com/nspcc-dev/neo-go.git
synced 2025-02-01 23:40:35 +00:00
Merge pull request #3730 from nspcc-dev/tune-getaddr-trigger
network: take into account good known peers when thinking of GetAddr
This commit is contained in:
commit
c84dac501d
1 changed files with 1 additions and 1 deletions
|
@ -499,7 +499,7 @@ func (s *Server) run() {
|
|||
s.discovery.RequestRemote(min(s.AttemptConnPeers, optimalN-peerN))
|
||||
}
|
||||
|
||||
if addrCheckTimeout || s.discovery.PoolCount() < s.AttemptConnPeers {
|
||||
if addrCheckTimeout || s.discovery.PoolCount()+peerN < s.AttemptConnPeers {
|
||||
s.broadcastHPMessage(NewMessage(CMDGetAddr, payload.NewNullPayload()))
|
||||
addrCheckTimeout = false
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue