Merge pull request #394 from arvidn/forward-port-http-fix

forward port fix for web seeds not being used by torrents added by URL
This commit is contained in:
Arvid Norberg 2016-01-17 17:47:25 -05:00
commit fa391d4961
2 changed files with 6 additions and 1 deletions

View File

@ -80,6 +80,7 @@
* almost completely changed the storage interface (for custom storage)
* added support for hashing pieces in multiple threads
* fix bug where web seeds were not used for torrents added by URL
* fix support for symlinks on windows
* fix long filename issue (on unixes)
* fixed performance bug in DHT torrent eviction

View File

@ -479,7 +479,7 @@ namespace libtorrent
TORRENT_ASSERT(num_torrents == int(m_ses.m_torrents.size()));
// if the user added any trackers while downloading the
// .torrent file, serge them into the new tracker list
// .torrent file, merge them into the new tracker list
std::vector<announce_entry> new_trackers = m_torrent_file->trackers();
for (std::vector<announce_entry>::iterator i = m_trackers.begin()
, end(m_trackers.end()); i != end; ++i)
@ -605,6 +605,10 @@ namespace libtorrent
}
m_trackers.swap(new_trackers);
// add the web seeds from the .torrent file
std::vector<web_seed_entry> const& web_seeds = m_torrent_file->web_seeds();
m_web_seeds.insert(m_web_seeds.end(), web_seeds.begin(), web_seeds.end());
#if !defined(TORRENT_DISABLE_ENCRYPTION) && !defined(TORRENT_DISABLE_EXTENSIONS)
hasher h;
h.update("req2", 4);