25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-30 16:36:29 +01:00

Provide stacktrace in log report when module start fails

This commit is contained in:
Badlop 2011-08-13 17:23:33 +02:00
parent 4a4a7afe22
commit afad6c75a0

View File

@ -86,8 +86,8 @@ start_module2(Host, Module, Opts) ->
catch Class:Reason ->
del_module_mnesia(Host, Module),
ets:delete(ejabberd_modules, {Module, Host}),
ErrorText = io_lib:format("Problem starting the module ~p for host ~p ~n options: ~p~n ~p: ~p",
[Module, Host, Opts, Class, Reason]),
ErrorText = io_lib:format("Problem starting the module ~p for host ~p ~n options: ~p~n ~p: ~p~n stacktarce: ~p",
[Module, Host, Opts, Class, Reason, erlang:get_stacktrace()]),
?CRITICAL_MSG(ErrorText, []),
case is_app_running(ejabberd) of
true ->