From 0eefd598cba2ca39b318a060b01ba0532fbb0077 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Wed, 10 Jul 2013 07:45:10 +0200 Subject: net.dns, net.adns: Make sure errors from net.server are propagated (thanks asterix) --- net/adns.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'net/adns.lua') diff --git a/net/adns.lua b/net/adns.lua index cd69a627..158747c6 100644 --- a/net/adns.lua +++ b/net/adns.lua @@ -68,9 +68,9 @@ function new_async_socket(sock, resolver) resolver:servfail(conn); -- Let the magic commence end end - handler = server.wrapclient(sock, "dns", 53, listener); + handler, err = server.wrapclient(sock, "dns", 53, listener); if not handler then - log("warn", "handler is nil"); + return nil, err; end handler.settimeout = function () end -- cgit v1.2.3