mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-22 16:20:52 +01:00
Start ezlib only if required, as it's optional (#1006)
This commit is contained in:
parent
74053b114e
commit
c985a2bd3d
@ -256,7 +256,6 @@ start_apps() ->
|
|||||||
ejabberd:start_app(fast_tls),
|
ejabberd:start_app(fast_tls),
|
||||||
ejabberd:start_app(fast_xml),
|
ejabberd:start_app(fast_xml),
|
||||||
ejabberd:start_app(stringprep),
|
ejabberd:start_app(stringprep),
|
||||||
ejabberd:start_app(ezlib),
|
|
||||||
ejabberd:start_app(cache_tab).
|
ejabberd:start_app(cache_tab).
|
||||||
|
|
||||||
opt_type(net_ticktime) ->
|
opt_type(net_ticktime) ->
|
||||||
|
@ -141,6 +141,7 @@ handle_call({starttls, TLSSocket}, _From, State) ->
|
|||||||
handle_call({compress, Data}, _From,
|
handle_call({compress, Data}, _From,
|
||||||
#state{socket = Socket, sock_mod = SockMod} =
|
#state{socket = Socket, sock_mod = SockMod} =
|
||||||
State) ->
|
State) ->
|
||||||
|
ejabberd:start_app(ezlib),
|
||||||
{ok, ZlibSocket} = ezlib:enable_zlib(SockMod,
|
{ok, ZlibSocket} = ezlib:enable_zlib(SockMod,
|
||||||
Socket),
|
Socket),
|
||||||
if Data /= undefined -> do_send(State, Data);
|
if Data /= undefined -> do_send(State, Data);
|
||||||
|
Loading…
Reference in New Issue
Block a user