From 1de690a74bc7fbe899f2a68f41b5efe5ad3835ec Mon Sep 17 00:00:00 2001 From: Igor Katson Date: Mon, 20 Nov 2023 01:55:27 +0000 Subject: [PATCH] nothing --- crates/librqbit/src/torrent_state.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/librqbit/src/torrent_state.rs b/crates/librqbit/src/torrent_state.rs index 8a8d9dc..12ba450 100644 --- a/crates/librqbit/src/torrent_state.rs +++ b/crates/librqbit/src/torrent_state.rs @@ -1086,7 +1086,7 @@ impl PeerHandler { None => match self.state.reserve_next_needed_piece(handle) { Some(next) => next, None => { - if self.state.get_left_to_download() == 0 { + if self.state.is_finished() { debug!("nothing left to download, closing requester"); return Ok(()); }