mirror of
https://github.com/processone/ejabberd.git
synced 2024-12-20 17:27:00 +01:00
Fixes a leak of ejabberd_receiver processes.
When a (non-frontend) socket module without any custom receiver fails to start, the newly created ejabberd_receiver process needs to be properly closed.
This commit is contained in:
parent
dccaff0544
commit
2f68733708
@ -87,7 +87,13 @@ start(Module, SockMod, Socket, Opts) ->
|
||||
end,
|
||||
ReceiverMod:become_controller(Receiver, Pid);
|
||||
{error, _Reason} ->
|
||||
SockMod:close(Socket)
|
||||
SockMod:close(Socket),
|
||||
case ReceiverMod of
|
||||
ejabberd_receiver ->
|
||||
ReceiverMod:close(Receiver);
|
||||
_ ->
|
||||
ok
|
||||
end
|
||||
end;
|
||||
independent ->
|
||||
ok;
|
||||
|
Loading…
Reference in New Issue
Block a user