forked from premiere/premiere-libtorrent
fix to immediately unchoke another peer if an unchoked peer is disconnected
This commit is contained in:
parent
c709cd28a8
commit
cb1fce0d62
|
@ -2092,7 +2092,15 @@ namespace libtorrent
|
|||
}
|
||||
|
||||
if (!p->is_choked())
|
||||
{
|
||||
--m_num_uploads;
|
||||
m_ses.m_unchoke_time_scaler = 0;
|
||||
}
|
||||
|
||||
if (p->peer_info_struct() && p->peer_info_struct()->optimistically_unchoked)
|
||||
{
|
||||
m_ses.m_optimistic_unchoke_time_scaler = 0;
|
||||
}
|
||||
|
||||
m_policy.connection_closed(*p);
|
||||
p->set_peer_info(0);
|
||||
|
|
Loading…
Reference in New Issue