Fix DoFileSearch for non-ASCII paths on Windows
It didn't work when there were non-ASCII characters in the directories argument, but it worked fine with non-ASCII characters in names of found files and folders.
This commit is contained in:
parent
951f6400fb
commit
6f98915c32
|
@ -100,12 +100,12 @@ std::vector<std::string> DoFileSearch(const std::vector<std::string>& directorie
|
|||
if (recursive)
|
||||
{
|
||||
// TODO use fs::directory_options::follow_directory_symlink ?
|
||||
for (auto& entry : fs::recursive_directory_iterator(fs::path(directory)))
|
||||
for (auto& entry : fs::recursive_directory_iterator(fs::u8path(directory)))
|
||||
add_filtered(entry);
|
||||
}
|
||||
else
|
||||
{
|
||||
for (auto& entry : fs::directory_iterator(fs::path(directory)))
|
||||
for (auto& entry : fs::directory_iterator(fs::u8path(directory)))
|
||||
add_filtered(entry);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue