diff options
Diffstat (limited to 'src/tcp.c')
-rw-r--r-- | src/tcp.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -337,13 +337,13 @@ error: | |||
337 | static int meth_getpeername(lua_State *L) | 337 | static int meth_getpeername(lua_State *L) |
338 | { | 338 | { |
339 | p_tcp tcp = (p_tcp) auxiliar_checkgroup(L, "tcp{any}", 1); | 339 | p_tcp tcp = (p_tcp) auxiliar_checkgroup(L, "tcp{any}", 1); |
340 | return inet_meth_getpeername(L, &tcp->sock); | 340 | return inet_meth_getpeername(L, &tcp->sock, tcp->family); |
341 | } | 341 | } |
342 | 342 | ||
343 | static int meth_getsockname(lua_State *L) | 343 | static int meth_getsockname(lua_State *L) |
344 | { | 344 | { |
345 | p_tcp tcp = (p_tcp) auxiliar_checkgroup(L, "tcp{any}", 1); | 345 | p_tcp tcp = (p_tcp) auxiliar_checkgroup(L, "tcp{any}", 1); |
346 | return inet_meth_getsockname(L, &tcp->sock); | 346 | return inet_meth_getsockname(L, &tcp->sock, tcp->family); |
347 | } | 347 | } |
348 | 348 | ||
349 | /*-------------------------------------------------------------------------*\ | 349 | /*-------------------------------------------------------------------------*\ |