From b9e754d14dc17e4b1522f4476bda0813c90b5d9d Mon Sep 17 00:00:00 2001 From: Arvid Norberg Date: Tue, 21 Jun 2011 05:10:32 +0000 Subject: [PATCH] mark some invariant checks in disk_io_thread as expensive --- src/disk_io_thread.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/disk_io_thread.cpp b/src/disk_io_thread.cpp index 055356545..e62df25e5 100644 --- a/src/disk_io_thread.cpp +++ b/src/disk_io_thread.cpp @@ -1081,7 +1081,7 @@ namespace libtorrent { if (p.blocks[k].buf) { -#ifndef TORRENT_DISABLE_POOL_ALLOCATOR +#if !defined TORRENT_DISABLE_POOL_ALLOCATOR && !defined TORRENT_NO_EXPENSIVE_INVARIANT_CHECK TORRENT_ASSERT(is_disk_buffer(p.blocks[k].buf)); #endif ++blocks; @@ -1105,7 +1105,7 @@ namespace libtorrent { if (p.blocks[k].buf) { -#ifndef TORRENT_DISABLE_POOL_ALLOCATOR +#if !defined TORRENT_DISABLE_POOL_ALLOCATOR && !defined TORRENT_NO_EXPENSIVE_INVARIANT_CHECK TORRENT_ASSERT(is_disk_buffer(p.blocks[k].buf)); #endif ++blocks;