change disk cache

This commit is contained in:
YouROK
2021-05-17 11:54:56 +03:00
parent 5664ede2da
commit 70b71dc279
4 changed files with 85 additions and 61 deletions

View File

@@ -109,6 +109,7 @@ func (t *Torrent) WaitInfo() bool {
case <-t.Torrent.GotInfo():
t.cache = t.bt.storage.GetCache(t.Hash())
t.cache.SetTorrent(t.Torrent)
go t.cache.LoadPiecesOnDisk()
return true
case <-t.closed:
return false