From 5fcfc87655fa4d4eda4c7779ab3039abfb53e2c4 Mon Sep 17 00:00:00 2001 From: kervala Date: Sat, 13 Feb 2016 23:33:27 +0100 Subject: [PATCH] Fixed: All files and directories names are using 8-bits locale at the moment, so don't mix with UTF-8 under Windows (we could improve that later but it'll need a lot of changes, especially for all fopen calls) --- code/nel/src/misc/path.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/code/nel/src/misc/path.cpp b/code/nel/src/misc/path.cpp index 41477db32..ee47fd494 100644 --- a/code/nel/src/misc/path.cpp +++ b/code/nel/src/misc/path.cpp @@ -1789,18 +1789,18 @@ std::string CFileContainer::getApplicationDirectory(const std::string &appName, if (appPath.empty()) { #ifdef NL_OS_WINDOWS - wchar_t buffer[MAX_PATH]; + char buffer[MAX_PATH]; #ifdef CSIDL_LOCAL_APPDATA if (local) { - SHGetSpecialFolderPathW(NULL, buffer, CSIDL_LOCAL_APPDATA, TRUE); + SHGetSpecialFolderPathA(NULL, buffer, CSIDL_LOCAL_APPDATA, TRUE); } else #endif { - SHGetSpecialFolderPathW(NULL, buffer, CSIDL_APPDATA, TRUE); + SHGetSpecialFolderPathA(NULL, buffer, CSIDL_APPDATA, TRUE); } - appPath = CPath::standardizePath(ucstring((ucchar*)buffer).toUtf8()); + appPath = CPath::standardizePath(buffer); #elif defined(NL_OS_MAC) appPath = CPath::standardizePath(getenv("HOME")); appPath += "/Library/Application Support/";