From e39b844af60c2679397df5da2be13d5141ec5b7a Mon Sep 17 00:00:00 2001 From: luigi2us Date: Thu, 17 Dec 2009 22:56:03 +0000 Subject: [PATCH] FileIO: one more experiment: now MKWii can be played without a save file AND saves its data successfully! git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4707 8ced0084-cf51-0410-be5f-012b33b47a6e --- Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_FileIO.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_FileIO.cpp b/Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_FileIO.cpp index 2aed0a62fd..8f5d20ea79 100644 --- a/Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_FileIO.cpp +++ b/Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_FileIO.cpp @@ -95,7 +95,7 @@ bool CWII_IPC_HLE_Device_FileIO::Open(u32 _CommandAddress, u32 _Mode) switch(_Mode) { case ISFS_OPEN_READ: m_pFileHandle = fopen(m_Filename.c_str(), "rb"); break; - case ISFS_OPEN_WRITE: m_pFileHandle = fopen(m_Filename.c_str(), "wb"); break; + case ISFS_OPEN_WRITE: m_pFileHandle = fopen(m_Filename.c_str(), "r+b"); break; // MK Wii gets here corrupting its saves, however using rb+ mode works fine // TODO : figure it properly... case ISFS_OPEN_RW: m_pFileHandle = fopen(m_Filename.c_str(), "r+b"); break;