aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorFlorian Zeitz <florob@babelmonkeys.de>2011-06-14 20:30:40 +0200
committerSam Roberts <vieuxtech@gmail.com>2012-04-11 13:33:34 -0700
commit5874d47f550a2f278ca35ccda96d49ccf0ca7e36 (patch)
treebd42f1f2761e8f7a87f7248cd09a31aeffeab77f /src
parentf871a29f27ea28dea480d0e061a6d6ec1670384b (diff)
downloadluasocket-5874d47f550a2f278ca35ccda96d49ccf0ca7e36.tar.gz
luasocket-5874d47f550a2f278ca35ccda96d49ccf0ca7e36.tar.bz2
luasocket-5874d47f550a2f278ca35ccda96d49ccf0ca7e36.zip
dns.getaddrinfo: Return proper error messages
Diffstat (limited to 'src')
-rw-r--r--src/inet.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/inet.c b/src/inet.c
index 758dbf8..962acec 100644
--- a/src/inet.c
+++ b/src/inet.c
@@ -109,7 +109,7 @@ static int inet_global_getaddrinfo(lua_State *L)
109 ret = getaddrinfo(hostname, NULL, &hints, &resolved); 109 ret = getaddrinfo(hostname, NULL, &hints, &resolved);
110 if (ret != 0) { 110 if (ret != 0) {
111 lua_pushnil(L); 111 lua_pushnil(L);
112 lua_pushstring(L, "getaddrinfo returned error"); 112 lua_pushstring(L, socket_gaistrerror(ret));
113 return 2; 113 return 2;
114 } 114 }
115 lua_newtable(L); 115 lua_newtable(L);