mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-14 06:05:53 +08:00
Fix of incorrect usage of wxString in fopen in AppUpdater and Downloader.
This commit is contained in:
parent
b7f0b51c3b
commit
447dd15681
@ -187,9 +187,9 @@ void FileGet::priv::get_perform()
|
||||
FILE* file;
|
||||
// open file for writting
|
||||
if (m_written == 0)
|
||||
file = fopen(temp_path_wstring.c_str(), "wb");
|
||||
file = fopen(into_u8(temp_path_wstring).c_str(), "wb");
|
||||
else
|
||||
file = fopen(temp_path_wstring.c_str(), "ab");
|
||||
file = fopen(into_u8(temp_path_wstring).c_str(), "ab");
|
||||
|
||||
//assert(file != NULL);
|
||||
if (file == NULL) {
|
||||
|
@ -222,7 +222,7 @@ boost::filesystem::path AppUpdater::priv::download_file(const DownloadAppData& d
|
||||
tmp_path += format(".%1%%2%", std::to_string(GUI::GLCanvas3D::timestamp_now()), ".download");
|
||||
FILE* file;
|
||||
wxString temp_path_wstring(tmp_path.wstring());
|
||||
file = fopen(temp_path_wstring.c_str(), "wb");
|
||||
file = fopen(GUI::into_u8(temp_path_wstring).c_str(), "wb");
|
||||
assert(file != NULL);
|
||||
if (file == NULL) {
|
||||
std::string line1 = GUI::format(_u8L("Download from %1% couldn't start:"), data.url);
|
||||
|
Loading…
x
Reference in New Issue
Block a user