Remove outdated code

PR #18908.
This commit is contained in:
Vladimir Golovnev
2023-05-01 08:29:35 +03:00
committed by GitHub
parent 634eb4a183
commit 821e946bbe
2 changed files with 0 additions and 31 deletions

View File

@@ -36,19 +36,12 @@ NativeTorrentExtension::NativeTorrentExtension(const lt::torrent_handle &torrent
{
// NOTE: `data` may not exist if a torrent is added behind the scenes to download metadata
#ifdef QBT_USES_LIBTORRENT2
// libtorrent < 2.0.7 has a bug that add_torrent_alert is posted too early
// (before torrent is fully initialized and torrent extensions are created)
// so we have to fill "extension data" in add_torrent_alert handler and
// we have it already filled at this point
if (m_data)
{
m_data->status = m_torrentHandle.status();
m_data->trackers = m_torrentHandle.trackers();
m_data->urlSeeds = m_torrentHandle.url_seeds();
}
#endif
on_state(m_data ? m_data->status.state : m_torrentHandle.status({}).state);
}