1
0
Fork 0
mirror of https://github.com/processone/ejabberd synced 2025-10-03 09:49:18 +02:00

ejabberd_listener: Handle unix socket when logging remote client

This commit is contained in:
Badlop 2025-01-06 12:21:44 +01:00
parent afc54aeb20
commit bb2f398fa2

View file

@ -562,10 +562,12 @@ format_error(Reason) ->
end. end.
-spec format_endpoint(endpoint()) -> string(). -spec format_endpoint(endpoint()) -> string().
format_endpoint({Port, IP, _Transport}) -> format_endpoint({Port, IP, Transport}) ->
case Port of case Port of
<<"unix:", _/binary>> -> <<"unix:", _/binary>> ->
Port; Port;
<<>> when (IP == local) and (Transport == tcp) ->
"local-unix-socket-domain";
Unix when is_binary(Unix) -> Unix when is_binary(Unix) ->
Def = get_definitive_udsocket_path(Unix), Def = get_definitive_udsocket_path(Unix),
<<"unix:", Def/binary>>; <<"unix:", Def/binary>>;