1
0
mirror of https://github.com/nmap/nmap.git synced 2026-02-08 22:46:34 +00:00

Fix a crash on dns.query failure in dns-client-subnet-scan. Fixes #93

This commit is contained in:
dmiller
2016-01-07 05:45:48 +00:00
parent bc3ece44c9
commit e43e6fc278

View File

@@ -324,7 +324,7 @@ local get_addresses = function(address, mask, domain, nameserver, port)
local subnet = { family = nmap.address_family(), address = address, mask = mask }
local status, resp = dns.query(domain, {host = nameserver, port=port.number, protocol=port.protocol, retAll=true, subnet=subnet})
if ( not(status) ) then
return
return {}
end
if ( "table" ~= type(resp) ) then resp = { resp } end
return resp