24
1
mirror of https://github.com/processone/ejabberd.git synced 2024-06-18 22:15:20 +02:00

Handle unix sockets in misc:ip_to_list

This commit is contained in:
Paweł Chmielowski 2020-12-01 15:29:27 +01:00
parent d75d69d5d5
commit e937ff62fe

View File

@ -212,6 +212,8 @@ encode_base64(Data) ->
-spec ip_to_list(inet:ip_address() | undefined |
{inet:ip_address(), inet:port_number()}) -> binary().
ip_to_list({local, _}) ->
<<"unix">>;
ip_to_list({IP, _Port}) ->
ip_to_list(IP);
%% This function clause could use inet_parse too: