24
1
mirror of https://github.com/processone/ejabberd.git synced 2024-06-12 21:52:07 +02:00

Fix STUN startup

This commit is contained in:
Evgeniy Khramtsov 2013-05-02 20:00:04 +10:00
parent c801bd9411
commit 8fc80178b6
2 changed files with 12 additions and 1 deletions

View File

@ -242,6 +242,8 @@ delete_pid_file() ->
start_apps() ->
application:start(sasl),
application:start(crypto),
application:start(public_key),
application:start(ssl),
application:start(tls),
application:start(xml),

View File

@ -594,7 +594,8 @@ check_rate_limit(Interval) ->
validate_cfg(L) ->
lists:map(
fun({PortIPTransport, Mod, Opts}) when is_atom(Mod), is_list(Opts) ->
fun({PortIPTransport, Mod1, Opts}) when is_atom(Mod1), is_list(Opts) ->
Mod = prepare_mod(Mod1),
case PortIPTransport of
Port when ?IS_PORT(Port) ->
{Port, Mod, Opts};
@ -619,3 +620,11 @@ prepare_ip(IP) when is_list(IP) ->
Addr;
prepare_ip(IP) when is_binary(IP) ->
prepare_ip(binary_to_list(IP)).
prepare_mod(ejabberd_stun) ->
prepare_mod(stun);
prepare_mod(stun) ->
application:start(stun),
stun;
prepare_mod(Mod) ->
Mod.