mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-08-22 06:13:36 -07:00
parent
8306a41d11
commit
d7e9533e8c
1 changed files with 15 additions and 12 deletions
|
@ -4445,21 +4445,24 @@ void Session::startUpTorrents()
|
||||||
}
|
}
|
||||||
else if (torrentID == torrentIDv2)
|
else if (torrentID == torrentIDv2)
|
||||||
{
|
{
|
||||||
torrentID = torrentIDv1;
|
if (isHybrid)
|
||||||
needStore = true;
|
|
||||||
m_resumeDataStorage->remove(torrentIDv2);
|
|
||||||
|
|
||||||
if (indexedTorrents.contains(torrentID))
|
|
||||||
{
|
{
|
||||||
skippedIDs.insert(torrentID);
|
torrentID = torrentIDv1;
|
||||||
|
needStore = true;
|
||||||
|
m_resumeDataStorage->remove(torrentIDv2);
|
||||||
|
|
||||||
const std::optional<LoadTorrentParams> loadPreferredResumeDataResult = startupStorage->load(torrentID);
|
if (indexedTorrents.contains(torrentID))
|
||||||
if (loadPreferredResumeDataResult)
|
|
||||||
{
|
{
|
||||||
std::shared_ptr<lt::torrent_info> ti = resumeData.ltAddTorrentParams.ti;
|
skippedIDs.insert(torrentID);
|
||||||
resumeData = *loadPreferredResumeDataResult;
|
|
||||||
if (!resumeData.ltAddTorrentParams.ti)
|
const std::optional<LoadTorrentParams> loadPreferredResumeDataResult = startupStorage->load(torrentID);
|
||||||
resumeData.ltAddTorrentParams.ti = ti;
|
if (loadPreferredResumeDataResult)
|
||||||
|
{
|
||||||
|
std::shared_ptr<lt::torrent_info> ti = resumeData.ltAddTorrentParams.ti;
|
||||||
|
resumeData = *loadPreferredResumeDataResult;
|
||||||
|
if (!resumeData.ltAddTorrentParams.ti)
|
||||||
|
resumeData.ltAddTorrentParams.ti = ti;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue