Eluna fix build

This commit is contained in:
Rochet2
2014-04-25 13:16:13 +03:00
committed by Foereaper
parent 404cbf3d11
commit c998575221
2 changed files with 2 additions and 2 deletions

View File

@@ -78,7 +78,7 @@ bool StartEluna()
std::string folderpath = sConfigMgr->GetStringDefault("Eluna.ScriptPath", "lua_scripts");
#if PLATFORM == PLATFORM_UNIX || PLATFORM == PLATFORM_APPLE
if (folderpath[0] == '~')
if (const char* home = getenv("HOME");)
if (const char* home = getenv("HOME"))
folderpath.replace(0, 1, home);
#endif
ELUNA_LOG_INFO("[Eluna]: Searching scripts from `%s`", folderpath.c_str());