24
1
mirror of https://github.com/processone/ejabberd.git synced 2024-06-04 21:27:16 +02:00

Windows does not have /tmp, fallback to /home/chris/conf

This commit is contained in:
Christophe Romain 2017-11-30 15:32:09 +01:00
parent a5849a0dab
commit 395b74a89f

View File

@ -1053,7 +1053,10 @@ init_mssql(Host) ->
end. end.
tmp_dir() -> tmp_dir() ->
filename:join(["/tmp", "ejabberd"]). case os:type() of
{win32, _} -> filename:join([os:getenv("HOME"), "conf"]);
_ -> filename:join(["/tmp", "ejabberd"])
end.
odbc_config() -> odbc_config() ->
filename:join(tmp_dir(), "odbc.ini"). filename:join(tmp_dir(), "odbc.ini").