mirror of
https://github.com/ipfs/kubo.git
synced 2026-02-21 18:37:45 +08:00
fix: set peerset size
addresses https://github.com/jbenet/go-ipfs/pull/438#discussion_r21952271 License: MIT Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
This commit is contained in:
parent
e36d656632
commit
45faa4d7a0
@ -22,7 +22,7 @@ func NewPeerSet() *PeerSet {
|
||||
func NewLimitedPeerSet(size int) *PeerSet {
|
||||
ps := new(PeerSet)
|
||||
ps.ps = make(map[string]bool)
|
||||
ps.size = -1
|
||||
ps.size = size
|
||||
return ps
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user