From 81533f5a28be906d65467721822c3fd86e49f504 Mon Sep 17 00:00:00 2001 From: cy33hc Date: Sat, 30 May 2026 21:33:09 -0700 Subject: [PATCH] skip download request where client cannot be found --- source/server/http_server.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/source/server/http_server.cpp b/source/server/http_server.cpp index 0aebc77..412faa1 100644 --- a/source/server/http_server.cpp +++ b/source/server/http_server.cpp @@ -187,7 +187,7 @@ namespace HttpServer RemoteClient *tmp_client = GetRemoteClient(&(bg_download_list[i].host_info)); if (tmp_client == nullptr) { - break; + continue;; } g_bytes_transfered = &(bg_download_list[i].bytes_transfered); @@ -227,6 +227,11 @@ namespace HttpServer { // Resume interrupted download RemoteClient *tmp_client = GetRemoteClient(&(bg_download_list[i].host_info)); + if (tmp_client == nullptr) + { + continue; + } + g_bytes_transfered = &(bg_download_list[i].bytes_transfered); if (bg_download_list[i].host_info.type == CLIENT_TYPE_FTP) {