fix issue with peers not updated on metadata from magnet links

This commit is contained in:
arvidn 2017-03-05 19:23:10 -05:00 committed by Arvid Norberg
parent 9a63d4696e
commit af07ce1f25
2 changed files with 4 additions and 1 deletions

View File

@ -1,3 +1,5 @@
* fix issue with peers not updated on metadata from magnet links
1.1.2 release
* default TOS marking to 0x20

View File

@ -8770,6 +8770,7 @@ namespace libtorrent
}
#endif
bool const notify_initialized = !m_connections_initialized;
m_connections_initialized = true;
m_files_checked = true;
@ -8783,7 +8784,7 @@ namespace libtorrent
// all peer connections have to initialize themselves now that the metadata
// is available
if (!m_connections_initialized)
if (notify_initialized)
{
if (pc->is_disconnecting()) continue;
pc->on_metadata_impl();