Add lock for repairs
This commit is contained in:
@@ -168,6 +168,7 @@ func (t *TorrentManager) getMoreInfo(rdTorrent realdebrid.Torrent) *Torrent {
|
||||
OriginalName: info.OriginalName,
|
||||
Added: info.Added,
|
||||
Hash: info.Hash,
|
||||
Lock: &sync.Mutex{},
|
||||
}
|
||||
// SelectedFiles is a subset of Files with only the selected ones
|
||||
// it also has a Link field, which can be empty
|
||||
@@ -233,6 +234,7 @@ func (t *TorrentManager) mergeToMain(existing, toMerge *Torrent) Torrent {
|
||||
Unfixable: existing.Unfixable || toMerge.Unfixable,
|
||||
UnassignedLinks: existing.UnassignedLinks.Union(toMerge.UnassignedLinks),
|
||||
BrokenLinks: existing.BrokenLinks.Union(toMerge.BrokenLinks),
|
||||
Lock: &sync.Mutex{},
|
||||
}
|
||||
|
||||
// this function triggers only when we have a new DownloadedID
|
||||
|
||||
Reference in New Issue
Block a user