diff options
| author | Glenn Rice <glennricster@gmail.com> | 2010-02-03 03:27:32 +0000 |
|---|---|---|
| committer | Glenn Rice <glennricster@gmail.com> | 2010-02-03 03:27:32 +0000 |
| commit | afbf86eaeee2bb759cc4dad307b8366646250480 (patch) | |
| tree | 767222603db4c01924ce3cdeae822e96168e2b19 | |
| parent | fb4f0edb85823deebaa63dcd6b8389fc1e800984 (diff) | |
Revert commit 4997 and fix in a way that is more consistent with the structure
before the global build patch
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4999 8ced0084-cf51-0410-be5f-012b33b47a6e
| -rw-r--r-- | Source/Core/Common/Src/FileUtil.cpp | 4 | ||||
| -rw-r--r-- | Source/Core/Common/Src/FileUtil.h | 1 | ||||
| -rw-r--r-- | Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_FileIO.cpp | 9 |
3 files changed, 8 insertions, 6 deletions
diff --git a/Source/Core/Common/Src/FileUtil.cpp b/Source/Core/Common/Src/FileUtil.cpp index 9688e41fdc..e0b64e1f43 100644 --- a/Source/Core/Common/Src/FileUtil.cpp +++ b/Source/Core/Common/Src/FileUtil.cpp @@ -619,6 +619,7 @@ const char *GetUserPath(int DirIDX) static char UserDir[MAX_PATH] = {0}; static char GCUserDir[MAX_PATH] = {0}; static char WiiUserDir[MAX_PATH] = {0}; + static char WiiRootDir[MAX_PATH] = {0}; static char ConfigDir[MAX_PATH] = {0}; static char GameConfigDir[MAX_PATH] = {0}; static char MapsDir[MAX_PATH] = {0}; @@ -668,6 +669,7 @@ const char *GetUserPath(int DirIDX) snprintf(GCUserDir, sizeof(GCUserDir), "%s" GC_USER_DIR DIR_SEP, UserDir); snprintf(WiiUserDir, sizeof(WiiUserDir), "%s" WII_USER_DIR DIR_SEP, UserDir); + snprintf(WiiRootDir, sizeof(WiiRootDir), "%s" WII_USER_DIR, UserDir); snprintf(ConfigDir, sizeof(ConfigDir), "%s" CONFIG_DIR DIR_SEP, UserDir); snprintf(GameConfigDir, sizeof(GameConfigDir), "%s" GAMECONFIG_DIR DIR_SEP, UserDir); snprintf(MapsDir, sizeof(MapsDir), "%s" MAPS_DIR DIR_SEP, UserDir); @@ -702,6 +704,8 @@ const char *GetUserPath(int DirIDX) return GCUserDir; case D_WIIUSER_IDX: return WiiUserDir; + case D_WIIROOT_IDX: + return WiiRootDir; case D_CONFIG_IDX: return ConfigDir; case D_GAMECONFIG_IDX: diff --git a/Source/Core/Common/Src/FileUtil.h b/Source/Core/Common/Src/FileUtil.h index f180b8faf0..92d2a3e3fb 100644 --- a/Source/Core/Common/Src/FileUtil.h +++ b/Source/Core/Common/Src/FileUtil.h @@ -29,6 +29,7 @@ enum { D_USER_IDX, D_GCUSER_IDX, D_WIIUSER_IDX, + D_WIIROOT_IDX, D_CONFIG_IDX, D_GAMECONFIG_IDX, D_MAPS_IDX, 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 727e83c979..d6a736cfc0 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 @@ -30,14 +30,11 @@ std::string HLE_IPC_BuildFilename(const char* _pFilename, int _size) char Buffer[128]; memcpy(Buffer, _pFilename, _size); - std::string Filename = std::string(File::GetUserPath(D_WIIUSER_IDX)); + std::string Filename = std::string(File::GetUserPath(D_WIIROOT_IDX)); if (Buffer[1] == '0') - Filename += std::string("title/"); // this looks and feel like a hack... + Filename += std::string("/title"); // this looks and feel like a hack... - if (Buffer[0] == '/') - Filename += Buffer + 1; - else - Filename += Buffer; + Filename += Buffer; return Filename; } |
