client.go | 7 +++---- diff --git a/client.go b/client.go index d832c237d268a1295640fe9d849cbe3f120afcc9..9aa99b070650341748e71c588d21cf2b14fd5bf5 100644 --- a/client.go +++ b/client.go @@ -198,7 +198,7 @@ cl.dopplegangerAddrs = make(map[string]struct{}) cl.torrents = make(map[metainfo.Hash]*Torrent) cl.dialRateLimiter = rate.NewLimiter(10, 10) cl.activeAnnounceLimiter.SlotsPerKey = 2 - + cl.event.L = cl.locker() cl.ipBlockList = cfg.IPBlocklist } @@ -219,7 +219,7 @@ cl.Close() cl = nil } }() - + storageImpl := cfg.DefaultStorage if storageImpl == nil { // We'd use mmap by default but HFS+ doesn't support sparse files. @@ -1112,7 +1112,7 @@ metadataChanged: sync.Cond{ L: cl.locker(), }, - webSeeds: make(map[string]*Peer), + webSeeds: make(map[string]*Peer), gotMetainfoC: make(chan struct{}), } t.networkingEnabled.Set() @@ -1444,7 +1444,6 @@ } } return nil } - func (cl *Client) publicIp(peer net.IP) net.IP { // TODO: Use BEP 10 to determine how peers are seeing us.