diff options
author | Sebastian Valle <subv2112@gmail.com> | 2018-07-19 22:23:32 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-07-19 22:23:32 +0200 |
commit | 78dd1cd44103d5b23903fb29ebad87e9c8fdacda (patch) | |
tree | dafd1a532727899799a26cef2251531febde00cb | |
parent | Merge pull request #714 from lioncash/index (diff) | |
parent | Filesystem: Return EntryType::Directory for the root directory. (diff) | |
download | yuzu-78dd1cd44103d5b23903fb29ebad87e9c8fdacda.tar yuzu-78dd1cd44103d5b23903fb29ebad87e9c8fdacda.tar.gz yuzu-78dd1cd44103d5b23903fb29ebad87e9c8fdacda.tar.bz2 yuzu-78dd1cd44103d5b23903fb29ebad87e9c8fdacda.tar.lz yuzu-78dd1cd44103d5b23903fb29ebad87e9c8fdacda.tar.xz yuzu-78dd1cd44103d5b23903fb29ebad87e9c8fdacda.tar.zst yuzu-78dd1cd44103d5b23903fb29ebad87e9c8fdacda.zip |
-rw-r--r-- | src/core/hle/service/filesystem/filesystem.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/core/hle/service/filesystem/filesystem.cpp b/src/core/hle/service/filesystem/filesystem.cpp index 55282f3af..dffcdfbaf 100644 --- a/src/core/hle/service/filesystem/filesystem.cpp +++ b/src/core/hle/service/filesystem/filesystem.cpp @@ -193,6 +193,10 @@ ResultVal<FileSys::EntryType> VfsDirectoryServiceWrapper::GetEntryType( if (dir == nullptr) return FileSys::ERROR_PATH_NOT_FOUND; auto filename = FileUtil::GetFilename(path); + // TODO(Subv): Some games use the '/' path, find out what this means. + if (filename.empty()) + return MakeResult(FileSys::EntryType::Directory); + if (dir->GetFile(filename) != nullptr) return MakeResult(FileSys::EntryType::File); if (dir->GetSubdirectory(filename) != nullptr) |