fix one more assert (hopefully)

This commit is contained in:
Arvid Norberg 2010-11-14 10:57:10 +00:00
parent 2353cc8ec2
commit 94a25a3953
1 changed files with 1 additions and 4 deletions

View File

@ -531,10 +531,7 @@ namespace libtorrent
write_pe_vc_cryptofield(send_buf, crypto_provide, pad_size); write_pe_vc_cryptofield(send_buf, crypto_provide, pad_size);
m_RC4_handler->encrypt(send_buf.end - encrypt_size, encrypt_size); m_RC4_handler->encrypt(send_buf.end - encrypt_size, encrypt_size);
#ifdef TORRENT_DEBUG #ifdef TORRENT_DEBUG
const int packet_size = 20 + 20 + 8 + 4 + 2 + pad_size + 2; m_encrypted_bytes = send_buffer_size();
TORRENT_ASSERT(send_buffer_size() - packet_size == m_encrypted_bytes);
m_encrypted_bytes += packet_size;
TORRENT_ASSERT(m_encrypted_bytes == send_buffer_size());
#endif #endif
TORRENT_ASSERT(send_buf.begin == send_buf.end); TORRENT_ASSERT(send_buf.begin == send_buf.end);