}
func (t *Torrent) updateAllPiecePriorities(reason updateRequestReason) {
+ if !t.haveInfo() {
+ return
+ }
t.updatePiecePriorities(0, t.numPieces(), reason)
}
if !t.dataDownloadDisallowed.Clear() {
return
}
+ t.updateAllPiecePriorities("data download allowed")
t.iterPeers(func(p *Peer) {
p.onNeedUpdateRequests("allow data download")
})
// Webseed requests are issued globally so per-connection reasons or handling make no sense.
func (me *webseedPeer) onNeedUpdateRequests(reason updateRequestReason) {
// Too many reasons here: Can't predictably determine when we need to rerun updates.
+ // TODO: Can trigger this when we have Client-level active-requests map.
//me.peer.cl.scheduleImmediateWebseedRequestUpdate(reason)
}