From 9315851cdf0cf5f48a8868e705730347fb582569 Mon Sep 17 00:00:00 2001 From: Arvid Norberg Date: Thu, 16 Aug 2007 19:36:33 +0000 Subject: [PATCH] fixed assert in request_a_block. Fixes #125 --- src/policy.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/policy.cpp b/src/policy.cpp index ab1606a73..129f10a3b 100755 --- a/src/policy.cpp +++ b/src/policy.cpp @@ -189,7 +189,8 @@ namespace libtorrent // infinite loop, fighting to request the same blocks. void request_a_block(torrent& t, peer_connection& c) { - assert(!t.is_seed()); + if (t.is_seed()) return; + assert(t.valid_metadata()); assert(c.peer_info_struct() != 0 || !dynamic_cast(&c)); int num_requests = c.desired_queue_size()