diff --git a/.vscode/settings.json b/.vscode/settings.json index cb7812b..247350a 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -21,7 +21,7 @@ ], "visualizerFile": "${workspaceRoot}/.vscode/qt5.natvis", "args": [ - "-n", "2" + "-n", "1" ] }, "cmake.environment": { diff --git a/client/client.cpp b/client/client.cpp index ec5d5b5..6efb039 100644 --- a/client/client.cpp +++ b/client/client.cpp @@ -376,8 +376,17 @@ bool CClient::request_update_list(const std::string& param) std::string handled_content; for (const auto& item : vec) { std::string hitem = COfStr::trim(item); + if (hitem.empty()) { + continue; + } + logger_->info("---> check {}", hitem); auto v = COfStr::split(hitem, "|"); if (v.size() >= 2) { + if (!fs::exists(v[0])) { + logger_->error("file {} not exist.", v[0]); + valid = false; + break; + } handled_content.append(hitem + "\n"); continue; }