fix up some cases where we shouldn't be in end-game mode
This commit is contained in:
parent
8190744f0c
commit
ae76e77065
|
@ -1248,6 +1248,7 @@ namespace libtorrent
|
|||
peer_log("<== CHOKE");
|
||||
#endif
|
||||
m_peer_choked = true;
|
||||
set_endgame(false);
|
||||
|
||||
clear_request_queue();
|
||||
}
|
||||
|
|
|
@ -305,7 +305,10 @@ namespace libtorrent
|
|||
// there aren't enough. This means we're in end-game mode
|
||||
// as long as we have at least one request outstanding,
|
||||
// we shouldn't pick another piece
|
||||
c.set_endgame(true);
|
||||
// if we are attempting to download 'allowed' pieces
|
||||
// and can't find any, that doesn't count as end-game
|
||||
if (!c.has_peer_choked())
|
||||
c.set_endgame(true);
|
||||
|
||||
// if we don't have any potential busy blocks to request
|
||||
// or if we already have outstanding requests, don't
|
||||
|
|
Loading…
Reference in New Issue