forked from premiere/premiere-libtorrent
made some moer invariant checks count as expensive
This commit is contained in:
parent
b417a03877
commit
62e365225b
|
@ -3063,7 +3063,9 @@ namespace libtorrent
|
|||
|
||||
void peer_connection::fill_send_buffer()
|
||||
{
|
||||
#ifdef TORRENT_EXPENSIVE_INVARIANT_CHECKS
|
||||
INVARIANT_CHECK;
|
||||
#endif
|
||||
|
||||
boost::shared_ptr<torrent> t = m_torrent.lock();
|
||||
if (!t) return;
|
||||
|
@ -4022,7 +4024,9 @@ namespace libtorrent
|
|||
|
||||
void peer_connection::keep_alive()
|
||||
{
|
||||
#ifdef TORRENT_EXPENSIVE_INVARIANT_CHECKS
|
||||
INVARIANT_CHECK;
|
||||
#endif
|
||||
|
||||
time_duration d;
|
||||
d = time_now() - m_last_sent;
|
||||
|
|
|
@ -2177,7 +2177,9 @@ namespace libtorrent
|
|||
// a peer disconnects. The piece might be in any state
|
||||
void piece_picker::abort_download(piece_block block)
|
||||
{
|
||||
#ifdef TORRENT_EXPENSIVE_INVARIANT_CHECKS
|
||||
TORRENT_PIECE_PICKER_INVARIANT_CHECK;
|
||||
#endif
|
||||
|
||||
TORRENT_ASSERT(block.piece_index >= 0);
|
||||
TORRENT_ASSERT(block.block_index >= 0);
|
||||
|
|
Loading…
Reference in New Issue