From 00f8f9199b729748cf1c66716e83c80e771ea307 Mon Sep 17 00:00:00 2001 From: goeiecool9999 <> Date: Wed, 7 Sep 2022 23:03:37 +0200 Subject: [PATCH] Should have caught these way earlier. --- src/Cafe/Filesystem/fscDeviceHostFS.cpp | 6 +++--- src/Cafe/TitleList/SaveInfo.cpp | 2 +- src/Cafe/TitleList/SaveInfo.h | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Cafe/Filesystem/fscDeviceHostFS.cpp b/src/Cafe/Filesystem/fscDeviceHostFS.cpp index 8043b483..10d2546f 100644 --- a/src/Cafe/Filesystem/fscDeviceHostFS.cpp +++ b/src/Cafe/Filesystem/fscDeviceHostFS.cpp @@ -234,7 +234,7 @@ public: bool fscDeviceCreateDir(std::wstring_view path, void* ctx, sint32* fscStatus) override { - fs::path dirPath(path); + auto dirPath = FSPath::Convert(path); if (fs::exists(path)) { if (!fs::is_directory(dirPath)) @@ -253,7 +253,7 @@ public: bool fscDeviceRemoveFileOrDir(std::wstring_view path, void* ctx, sint32* fscStatus) override { *fscStatus = FSC_STATUS_OK; - fs::path _path(path); + auto _path = FSPath::Convert(path); std::error_code ec; if (!fs::exists(_path, ec)) { @@ -272,7 +272,7 @@ public: bool fscDeviceRename(std::wstring_view srcPath, std::wstring_view dstPath, void* ctx, sint32* fscStatus) override { *fscStatus = FSC_STATUS_OK; - fs::path _srcPath(srcPath); + auto _srcPath = FSPath::Convert(srcPath); fs::path _dstPath(dstPath); std::error_code ec; if (!fs::exists(_srcPath, ec)) diff --git a/src/Cafe/TitleList/SaveInfo.cpp b/src/Cafe/TitleList/SaveInfo.cpp index f5665ea5..7d3a0d83 100644 --- a/src/Cafe/TitleList/SaveInfo.cpp +++ b/src/Cafe/TitleList/SaveInfo.cpp @@ -16,7 +16,7 @@ std::string SaveInfo::GetStorageSubpathByTitleId(TitleId titleId) return fmt::format("usr/save/{:08x}/{:08x}", ((uint64)titleId) >> 32, (uint64)titleId & 0xFFFFFFFF); } -fs::path SaveInfo::GetSavePath(TitleId titleId) +FSPath SaveInfo::GetSavePath(TitleId titleId) { return ActiveSettings::GetMlcPath(GetStorageSubpathByTitleId(titleId)); } diff --git a/src/Cafe/TitleList/SaveInfo.h b/src/Cafe/TitleList/SaveInfo.h index 163d672f..41c8d970 100644 --- a/src/Cafe/TitleList/SaveInfo.h +++ b/src/Cafe/TitleList/SaveInfo.h @@ -21,7 +21,7 @@ public: private: static std::string GetStorageSubpathByTitleId(TitleId titleId); - static fs::path GetSavePath(TitleId titleId); + static FSPath GetSavePath(TitleId titleId); TitleId m_titleId; FSPath m_path;