mirror of
https://github.com/ipfs/kubo.git
synced 2026-03-04 07:48:00 +08:00
p2p/peer/peerstore: mu position + comment
This commit is contained in:
parent
d8a63be372
commit
71f2c4dee0
@ -62,9 +62,10 @@ func (e *expiringAddr) Expired() bool {
|
||||
type addressMap map[string]expiringAddr
|
||||
|
||||
type addressbook struct {
|
||||
sync.RWMutex // guards all fields
|
||||
|
||||
addrs map[ID]addressMap
|
||||
ttl time.Duration // initial ttl
|
||||
sync.RWMutex
|
||||
}
|
||||
|
||||
func newAddressbook() *addressbook {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user