From d4e0ea6c1ed75a6237f64b8ecabc0bf989cdb574 Mon Sep 17 00:00:00 2001 From: Arvid Norberg Date: Thu, 25 Sep 2008 22:08:18 +0000 Subject: [PATCH] added assert to make sure #365 doesn't happen --- src/torrent.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/torrent.cpp b/src/torrent.cpp index 2dad5b71e..84ebd3a25 100644 --- a/src/torrent.cpp +++ b/src/torrent.cpp @@ -3527,6 +3527,8 @@ namespace libtorrent { session_impl::mutex_t::scoped_lock l(m_ses.m_mutex); + if (is_paused()) TORRENT_ASSERT(num_peers() == 0); + if (!m_ses.m_queued_for_checking.empty()) { // if there are torrents waiting to be checked