summaryrefslogtreecommitdiff
path: root/Source/Core
diff options
context:
space:
mode:
authornakeee <nakeee@gmail.com>2008-12-01 15:41:02 +0000
committernakeee <nakeee@gmail.com>2008-12-01 15:41:02 +0000
commit751124bb68ba86cc853526ff63b96d4fd1258c31 (patch)
treed74743ae4e655137c56ef6cf2ba334a54f8f530a /Source/Core
parent159d33a25146aade449eaef75f8291e2b6f051f2 (diff)
small fixes
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1369 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Core')
-rw-r--r--Source/Core/Common/Src/FileUtil.cpp4
-rw-r--r--Source/Core/Common/Src/Paths.h2
-rw-r--r--Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE.cpp8
3 files changed, 7 insertions, 7 deletions
diff --git a/Source/Core/Common/Src/FileUtil.cpp b/Source/Core/Common/Src/FileUtil.cpp
index 3bee9ce29f..f018c7dae4 100644
--- a/Source/Core/Common/Src/FileUtil.cpp
+++ b/Source/Core/Common/Src/FileUtil.cpp
@@ -168,9 +168,7 @@ bool CreateDirectoryStructure(const std::string& _rFullPath)
{
// Find next sub path, support both \ and / directory separators
{
- size_t nextPosition = _rFullPath.find('/', Position);
- if (nextPosition == std::string::npos)
- nextPosition = _rFullPath.find('\\', Position);
+ size_t nextPosition = _rFullPath.find(DIR_SEP_CHR, Position);
Position = nextPosition;
if (Position == std::string::npos)
diff --git a/Source/Core/Common/Src/Paths.h b/Source/Core/Common/Src/Paths.h
index 54dad7d1c8..9cc0cad349 100644
--- a/Source/Core/Common/Src/Paths.h
+++ b/Source/Core/Common/Src/Paths.h
@@ -5,10 +5,12 @@
#define PLUGIN_PREFIX ""
#define PLUGIN_SUFFIX ".dll"
#define DIR_SEP "\\"
+#define DIR_SEP_CHR '\\'
#else
#define PLUGIN_PREFIX "lib"
#define PLUGIN_SUFFIX ".so"
#define DIR_SEP "/"
+#define DIR_SEP_CHR '/'
#endif
#define PLUGINS_DIR "Plugins"
diff --git a/Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE.cpp b/Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE.cpp
index e173ed1204..7240b666c0 100644
--- a/Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE.cpp
+++ b/Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE.cpp
@@ -234,13 +234,13 @@ bool AckCommand(u32 _Address)
// Let the game read the setting.txt file
void CopySettingsFile(std::string DeviceName)
{
- std::string Source;
+ std::string Source = FULL_WII_SYS_DIR;
if(Core::GetStartupParameter().bNTSC)
- Source = "Sys/Wii/setting-usa.txt";
+ Source += "setting-usa.txt";
else
- Source = "Sys/Wii/setting-eur.txt";
+ Source += "setting-eur.txt";
- std::string Target = "User/Wii" + DeviceName;
+ std::string Target = FULL_WII_USER_DIR + DeviceName;
// Check if the target dir exists, otherwise create it
std::string TargetDir = Target.substr(0, Target.find_last_of("/"));