don't ever send allowed fast messages to peers that doesn't support fast extensions

This commit is contained in:
Arvid Norberg 2010-01-17 21:26:47 +00:00
parent 3f87565992
commit 3c364731e8
1 changed files with 2 additions and 1 deletions

View File

@ -329,9 +329,10 @@ namespace libtorrent
{
INVARIANT_CHECK;
if (!m_supports_fast) return;
TORRENT_ASSERT(m_sent_handshake && m_sent_bitfield);
TORRENT_ASSERT(associated_torrent().lock()->valid_metadata());
TORRENT_ASSERT(m_supports_fast);
char msg[] = {0,0,0,5, msg_allowed_fast, 0, 0, 0, 0};
char* ptr = msg + 5;