diff --git a/src/peer_connection.cpp b/src/peer_connection.cpp index 87fbd62a9..26070d945 100755 --- a/src/peer_connection.cpp +++ b/src/peer_connection.cpp @@ -246,11 +246,6 @@ namespace libtorrent ++m_num_pieces; piece_list.push_back(i); } - else if (m_have_piece[i]) - { - --m_num_pieces; - m_torrent->peer_lost(i); - } } // shuffle the piece list @@ -699,6 +694,7 @@ namespace libtorrent } else if (!have && m_have_piece[i]) { + // this should probably not be allowed m_have_piece[i] = false; --m_num_pieces; m_torrent->peer_lost(i);