Fix bad init of Torrent.requestStrategy
This commit is contained in:
parent
35cdebdc3b
commit
cfc68d3ae6
|
@ -1039,11 +1039,11 @@ func (cl *Client) newTorrent(ih metainfo.Hash, specStorage storage.ClientImpl) (
|
||||||
maxEstablishedConns: cl.config.EstablishedConnsPerTorrent,
|
maxEstablishedConns: cl.config.EstablishedConnsPerTorrent,
|
||||||
|
|
||||||
networkingEnabled: true,
|
networkingEnabled: true,
|
||||||
requestStrategy: cl.config.DefaultRequestStrategy(t.requestStrategyCallbacks()),
|
|
||||||
metadataChanged: sync.Cond{
|
metadataChanged: sync.Cond{
|
||||||
L: cl.locker(),
|
L: cl.locker(),
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
t.requestStrategy = cl.config.DefaultRequestStrategy(t.requestStrategyCallbacks())
|
||||||
t.logger = cl.logger.WithValues(t).WithText(func(m log.Msg) string {
|
t.logger = cl.logger.WithValues(t).WithText(func(m log.Msg) string {
|
||||||
return fmt.Sprintf("%v: %s", t, m.Text())
|
return fmt.Sprintf("%v: %s", t, m.Text())
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in New Issue