1
0
mirror of https://github.com/d47081/qBittorrent.git synced 2025-01-23 13:04:23 +00:00

Revert "Fix unable to remove web seeds"

This reverts commit d657c872433aea21a2762880599e9dbee40db9a0.
This commit is contained in:
sledgehammer999 2019-11-25 15:34:37 +02:00
parent 9c1617b977
commit 005f0010ec
No known key found for this signature in database
GPG Key ID: 6E4A2D025B7CC9A2

View File

@ -2055,10 +2055,6 @@ bool Session::addTorrent_impl(CreateTorrentParams params, const MagnetUri &magne
, (patchedFastresumeData.constData() + patchedFastresumeData.size())}; , (patchedFastresumeData.constData() + patchedFastresumeData.size())};
p.flags |= lt::add_torrent_params::flag_use_resume_save_path; p.flags |= lt::add_torrent_params::flag_use_resume_save_path;
// load from .torrent file when fastresume doesn't contain the required `info` dict
if (!patchedFastresumeData.contains("4:infod"))
p.ti = torrentInfo.nativeInfo();
// Still setup the default parameters and let libtorrent handle // Still setup the default parameters and let libtorrent handle
// the parameter merging // the parameter merging
hasCompleteFastresume = false; hasCompleteFastresume = false;
@ -2066,10 +2062,6 @@ bool Session::addTorrent_impl(CreateTorrentParams params, const MagnetUri &magne
lt::error_code ec; lt::error_code ec;
p = lt::read_resume_data(fastresumeData, ec); p = lt::read_resume_data(fastresumeData, ec);
// load from .torrent file when fastresume doesn't contain the required `info` dict
if (!p.ti || !p.ti->is_valid())
p.ti = torrentInfo.nativeInfo();
// libtorrent will always apply `file_priorities` to torrents, // libtorrent will always apply `file_priorities` to torrents,
// if the field is present then the fastresume is considered to // if the field is present then the fastresume is considered to
// be correctly generated and should be complete. // be correctly generated and should be complete.
@ -2106,9 +2098,9 @@ bool Session::addTorrent_impl(CreateTorrentParams params, const MagnetUri &magne
static_cast<lt::download_priority_t::underlying_type>(priority)); static_cast<lt::download_priority_t::underlying_type>(priority));
#endif #endif
}); });
p.ti = torrentInfo.nativeInfo();
} }
p.ti = torrentInfo.nativeInfo();
} }
// Common // Common