mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2025-12-20 23:47:23 -06:00
Handle more torrent conflicts
PR #17668. This is a continuation of #17576. Handles the case when you add hybrid torrent by v1-only magnet link and this torrent is already known by its full hybrid info hash (i.e. by both v1 and v2 info hashes).
This commit is contained in:
committed by
GitHub
parent
4318de6dc5
commit
5cf6b1cbde
@@ -2014,10 +2014,10 @@ void TorrentImpl::handleMetadataReceivedAlert(const lt::metadata_received_alert
|
||||
qDebug("Metadata received for torrent %s.", qUtf8Printable(name()));
|
||||
|
||||
#ifdef QBT_USES_LIBTORRENT2
|
||||
const TorrentID prevTorrentID = id();
|
||||
const InfoHash prevInfoHash = infoHash();
|
||||
m_infoHash = InfoHash(m_nativeHandle.info_hashes());
|
||||
if (prevTorrentID != id())
|
||||
m_session->handleTorrentIDChanged(this, prevTorrentID);
|
||||
if (prevInfoHash != infoHash())
|
||||
m_session->handleTorrentInfoHashChanged(this, prevInfoHash);
|
||||
#endif
|
||||
|
||||
m_maintenanceJob = MaintenanceJob::HandleMetadata;
|
||||
|
||||
Reference in New Issue
Block a user