We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6218598 commit 9bb493cCopy full SHA for 9bb493c
http/client.lua
@@ -273,6 +273,11 @@ local function connect(options, timeout)
273
274
local records = lookup_records(options, timeout)
275
276
+ local lasterr, lasterrno = "The name does not resolve for the supplied parameters", nil
277
+ if records.n == 0 then
278
+ return nil, lasterr, lasterrno
279
+ end
280
+
281
local bind = options.bind
282
if bind ~= nil then
283
assert(type(bind) == "string")
@@ -303,7 +308,6 @@ local function connect(options, timeout)
303
308
nodelay = true;
304
309
}
305
310
306
- local lasterr, lasterrno = "The name does not resolve for the supplied parameters"
307
311
local i = 1
312
while i <= records.n do
313
local rec = records[i]
0 commit comments