forked from premiere/premiere-libtorrent
fix invariant check failure
This commit is contained in:
parent
d25d09cb70
commit
31cae31ccc
|
@ -1329,6 +1329,14 @@ namespace libtorrent
|
|||
m_have_piece.set_bit(index);
|
||||
++m_num_pieces;
|
||||
|
||||
if (is_seed())
|
||||
{
|
||||
m_peer_info->seed = true;
|
||||
m_upload_only = true;
|
||||
disconnect_if_redundant();
|
||||
if (is_disconnecting()) return;
|
||||
}
|
||||
|
||||
// only update the piece_picker if
|
||||
// we have the metadata and if
|
||||
// we're not a seed (in which case
|
||||
|
@ -1371,14 +1379,6 @@ namespace libtorrent
|
|||
p->superseed_piece(t->get_piece_to_super_seed(p->get_bitfield()));
|
||||
}
|
||||
}
|
||||
|
||||
if (is_seed())
|
||||
{
|
||||
m_peer_info->seed = true;
|
||||
m_upload_only = true;
|
||||
disconnect_if_redundant();
|
||||
if (is_disconnecting()) return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue