适配ZLToolKit

This commit is contained in:
xiongziliang
2023-12-02 19:49:28 +08:00
parent d555f6038a
commit c12a6f0aed
11 changed files with 26 additions and 26 deletions

View File

@@ -25,7 +25,7 @@ void HttpDownloader::startDownload(const string &url, const string &file_path, b
if (_file_path.empty()) {
_file_path = exeDir() + "HttpDownloader/" + MD5(url).hexdigest();
}
_save_file = File::create_file(_file_path.data(), append ? "ab" : "wb");
_save_file = File::create_file(_file_path, append ? "ab" : "wb");
if (!_save_file) {
auto strErr = StrPrinter << "打开文件失败:" << file_path << endl;
throw std::runtime_error(strErr);