fix issue with receiving interested before metadata (#2557)

This commit is contained in:
Arvid Norberg 2017-11-25 15:31:37 +01:00 committed by GitHub
parent 18176ae5b3
commit e15f466137
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 0 deletions

View File

@ -1,4 +1,5 @@
* fix issue with receiving interested before metadata
* fix IPv6 tracker announce issue
* restore path sanitization behavior of ":"
* fix listen socket issue when disabling "force_proxy" mode

View File

@ -565,6 +565,14 @@ namespace libtorrent
boost::shared_ptr<torrent> t = m_torrent.lock();
TORRENT_ASSERT(t);
if (!t->valid_metadata())
{
#ifndef TORRENT_DISABLE_LOGGING
peer_log(peer_log_alert::info, "ALLOWED", "skipping allowed set because we don't have metadata");
#endif
return;
}
if (t->super_seeding())
{
#ifndef TORRENT_DISABLE_LOGGING