0
Fork 0
mirror of https://github.com/ninenines/cowboy.git synced 2025-07-16 05:00:24 +00:00

Use the inet:ip_address() type instead of the user-defined one.

This commit is contained in:
Loïc Hoguin 2011-04-17 23:57:30 +02:00
parent 734f57aa8a
commit 9ad32386c0
5 changed files with 4 additions and 8 deletions

View file

@ -48,7 +48,7 @@ version(Req) ->
{Req#http_req.version, Req}.
-spec peer(Req::#http_req{})
-> {{Address::ip_address(), Port::port_number()}, Req::#http_req{}}.
-> {{Address::inet:ip_address(), Port::port_number()}, Req::#http_req{}}.
peer(Req=#http_req{socket=Socket, transport=Transport, peer=undefined}) ->
{ok, Peer} = Transport:peername(Socket),
{Peer, Req#http_req{peer=Peer}};