diff --git a/stratosphere/ams_mitm/source/fs_mitm/fs_mitm_service.cpp b/stratosphere/ams_mitm/source/fs_mitm/fs_mitm_service.cpp index 4ead9d21b..1a59aec63 100644 --- a/stratosphere/ams_mitm/source/fs_mitm/fs_mitm_service.cpp +++ b/stratosphere/ams_mitm/source/fs_mitm/fs_mitm_service.cpp @@ -99,12 +99,12 @@ namespace ams::mitm::fs { /* Verify we can open the save. */ FsFileSystem save_fs; R_UNLESS(R_SUCCEEDED(fsOpenSaveDataFileSystemFwd(this->forward_service.get(), &save_fs, space_id, &attribute)), sm::mitm::ResultShouldForwardToSession()); - const sf::cmif::DomainObjectId target_object_id{serviceGetObjectId(&save_fs.s)}; std::unique_ptr save_ifs = std::make_unique(save_fs); /* Mount the SD card using fs.mitm's session. */ FsFileSystem sd_fs; R_TRY(fsOpenSdCardFileSystem(&sd_fs)); + const sf::cmif::DomainObjectId target_object_id{serviceGetObjectId(&sd_fs.s)}; std::shared_ptr sd_ifs = std::make_shared(sd_fs); /* Verify that we can open the save directory, and that it exists. */ diff --git a/stratosphere/libstratosphere/include/stratosphere/fssystem/impl/fssystem_path_resolution_filesystem.hpp b/stratosphere/libstratosphere/include/stratosphere/fssystem/impl/fssystem_path_resolution_filesystem.hpp index 939085970..4797ab77e 100644 --- a/stratosphere/libstratosphere/include/stratosphere/fssystem/impl/fssystem_path_resolution_filesystem.hpp +++ b/stratosphere/libstratosphere/include/stratosphere/fssystem/impl/fssystem_path_resolution_filesystem.hpp @@ -92,7 +92,7 @@ namespace ams::fssystem::impl { R_TRY(static_cast(this)->ResolveFullPath(new_full_path, sizeof(new_full_path), new_path)); std::optional optional_lock = static_cast(this)->GetAccessorLock(); - return this->base_fs->RenameFile(old_path, new_path); + return this->base_fs->RenameFile(old_full_path, new_full_path); } virtual Result RenameDirectoryImpl(const char *old_path, const char *new_path) override { @@ -102,7 +102,7 @@ namespace ams::fssystem::impl { R_TRY(static_cast(this)->ResolveFullPath(new_full_path, sizeof(new_full_path), new_path)); std::optional optional_lock = static_cast(this)->GetAccessorLock(); - return this->base_fs->RenameDirectory(old_path, new_path); + return this->base_fs->RenameDirectory(old_full_path, new_full_path); } virtual Result GetEntryTypeImpl(fs::DirectoryEntryType *out, const char *path) override {