mirror of
https://github.com/OpenTTD/OpenTTD
synced 2026-01-21 19:32:54 +01:00
std::filesystem::path does not expect UTF-8 strings, so they must be converted to native format first (and back to utf-8 after.)
This commit is contained in:
@@ -489,7 +489,7 @@ bool TarScanner::AddFile(const std::string &filename, size_t, [[maybe_unused]] c
|
||||
|
||||
_tar_list[this->subdir][filename] = std::string{};
|
||||
|
||||
std::string filename_base = std::filesystem::path(filename).filename().string();
|
||||
std::string filename_base = FS2OTTD(std::filesystem::path(OTTD2FS(filename)).filename());
|
||||
SimplifyFileName(filename_base);
|
||||
|
||||
TarHeader th;
|
||||
|
||||
Reference in New Issue
Block a user