[ox/fs] Fix PassthroughFS mkdir for recursive cases
This commit is contained in:
parent
6653715795
commit
7d95dbaa99
@ -35,8 +35,7 @@ Error PassThroughFS::mkdir(const char *path, bool recursive) noexcept {
|
||||
if (recursive) {
|
||||
std::error_code ec;
|
||||
const auto isDir = std::filesystem::is_directory(p, ec);
|
||||
oxReturnError(OxError(ec.value(), "PassThroughFS: mkdir failed"));
|
||||
if (isDir) {
|
||||
if (isDir && !ec.value()) {
|
||||
success = true;
|
||||
} else {
|
||||
success = std::filesystem::create_directories(p, ec);
|
||||
|
Loading…
Reference in New Issue
Block a user