From 6119510a2302d3dacd48b92227d6ee5107c4821a Mon Sep 17 00:00:00 2001 From: yggverse Date: Fri, 1 Aug 2025 21:22:08 +0300 Subject: [PATCH] cleanup tmp folder after preload data resolve --- src/main.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main.rs b/src/main.rs index 8fe3f43..7855013 100644 --- a/src/main.rs +++ b/src/main.rs @@ -110,7 +110,6 @@ async fn main() -> Result<()> { if config.debug { println!("\t\tIndex `{i}`...") } - preload.clear(); // run the crawler in single thread for performance reasons, // use `timeout` argument option to skip the dead connections. match time::timeout( @@ -261,10 +260,12 @@ async fn main() -> Result<()> { session .delete(librqbit::api::TorrentIdOrHash::Id(id), false) .await?; - + // cleanup tmp + preload.clear(); if config.debug { println!("\t\t\tadd `{i}` to index.") } + // skip processed torrent on the next iteration assert!(processed.insert(i)) } Ok(_) => panic!(),