Core/WiiRoot: Fix NetPlay full Wii save sync not copying all the saves back to main NAND

This commit is contained in:
Techjar 2019-04-07 02:11:24 -04:00
parent 664cfb2ca5
commit 20530c2a96
1 changed files with 21 additions and 20 deletions

View File

@ -252,8 +252,8 @@ void CleanUpWiiFileSystemContents()
WARN_LOG(CORE, "Failed to copy Mii database to the NAND"); WARN_LOG(CORE, "Failed to copy Mii database to the NAND");
} }
const u64 title_id = SConfig::GetInstance().GetTitleID(); for (const u64 title_id : ios->GetES()->GetInstalledTitles())
{
const auto session_save = WiiSave::MakeNandStorage(ios->GetFS().get(), title_id); const auto session_save = WiiSave::MakeNandStorage(ios->GetFS().get(), title_id);
// FS won't write the save if the directory doesn't exist // FS won't write the save if the directory doesn't exist
@ -274,5 +274,6 @@ void CleanUpWiiFileSystemContents()
// Backup the existing save just in case it's still needed. // Backup the existing save just in case it's still needed.
WiiSave::Copy(user_save.get(), backup_save.get()); WiiSave::Copy(user_save.get(), backup_save.get());
WiiSave::Copy(session_save.get(), user_save.get()); WiiSave::Copy(session_save.get(), user_save.get());
}
} }
} // namespace Core } // namespace Core