invariant check fix

This commit is contained in:
Arvid Norberg 2009-03-31 18:01:12 +00:00
parent 3499913c59
commit 33912a0fb7
1 changed files with 1 additions and 1 deletions

View File

@ -4194,7 +4194,7 @@ namespace libtorrent
TORRENT_ASSERT(m_ses.has_peer((peer_connection*)this)); TORRENT_ASSERT(m_ses.has_peer((peer_connection*)this));
} }
if (t && !m_disconnecting) if (t && t->valid_metadata() && !m_disconnecting)
{ {
boost::optional<piece_block_progress> p = t?downloading_piece_progress():boost::optional<piece_block_progress>(); boost::optional<piece_block_progress> p = t?downloading_piece_progress():boost::optional<piece_block_progress>();
torrent_info const& ti = t->torrent_file(); torrent_info const& ti = t->torrent_file();