diff options
author | Evgeniy Khramtsov <ekhramtsov@process-one.net> | 2017-03-12 08:55:54 +0300 |
---|---|---|
committer | Evgeniy Khramtsov <ekhramtsov@process-one.net> | 2017-03-12 08:55:54 +0300 |
commit | 071c1dcb64e1ae3dbf63a7e835c2da01c80ec785 (patch) | |
tree | 962c37cba2e522d5d8b879e40ffa0e05c4b3a011 /src/xmpp_stream_in.erl | |
parent | Teach web admin about ip acl rules (diff) |
Return 'closed' instead of 'einval' on closed sockets
Diffstat (limited to 'src/xmpp_stream_in.erl')
-rw-r--r-- | src/xmpp_stream_in.erl | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/xmpp_stream_in.erl b/src/xmpp_stream_in.erl index c80fafe0..54168261 100644 --- a/src/xmpp_stream_in.erl +++ b/src/xmpp_stream_in.erl @@ -1104,6 +1104,8 @@ set_lang(Pkt, _) -> Pkt. -spec format_inet_error(atom()) -> string(). +format_inet_error(closed) -> + "connection closed"; format_inet_error(Reason) -> case inet:format_error(Reason) of "unknown POSIX error" -> atom_to_list(Reason); |