summaryrefslogtreecommitdiff
path: root/Source/Core/Common/Src/FileUtil.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Core/Common/Src/FileUtil.cpp')
-rw-r--r--Source/Core/Common/Src/FileUtil.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/Source/Core/Common/Src/FileUtil.cpp b/Source/Core/Common/Src/FileUtil.cpp
index 86ae07fa51..08d6836467 100644
--- a/Source/Core/Common/Src/FileUtil.cpp
+++ b/Source/Core/Common/Src/FileUtil.cpp
@@ -302,12 +302,12 @@ std::string GetUserDirectory()
return std::string("");
#else
char *homedir = getenv("HOME");
- if (!dir)
+ if (!homedir)
return std::string("");
#ifdef __APPLE__
- snprintf(path, sizeof(path), "%s/Library/Application Support/Dolphin");
+ snprintf(path, sizeof(path), "%s/Library/Application Support/Dolphin", homedir);
#else
- snprintf(path, sizeof(path), "%s/.dolphin"); // XXX changeme as appropriate
+ snprintf(path, sizeof(path), "%s/.dolphin", homedir); // XXX changeme as appropriate
#endif
#endif
return std::string(path);