浏览器下载插件

This commit is contained in:
zhongluofeng
2026-07-21 17:40:55 +08:00
parent 548b022426
commit 141547acb6
9 changed files with 1322 additions and 129 deletions
+3 -2
View File
@@ -758,9 +758,10 @@ impl Aria2Manager {
Err(_) => return,
};
let _ = rt.block_on(async {
// 给一个短超时,避免退出卡住
// 给 2 秒超时,让 aria2 有足够时间保存 session
// aria2 保存 session 可能涉及磁盘 I/O500ms 太短)
let _ = tokio::time::timeout(
std::time::Duration::from_millis(500),
std::time::Duration::from_millis(2000),
self.rpc_call("aria2.shutdown", vec![]),
)
.await;