Merge pull request #373 from Blizzard/fix-homedir-bug

Fix a bug in 'premake_init'
This commit is contained in:
Tom van Dijck 2015-12-18 09:56:50 -08:00
commit a0a96edbcd

View File

@ -154,6 +154,7 @@ int premake_init(lua_State* L)
/* find the user's home directory */
value = getenv("HOME");
if (!value) value = getenv("USERPROFILE");
if (!value) value = "~";
lua_pushstring(L, value);
lua_setglobal(L, "_USER_HOME_DIR");