avoid shadowing in dig module

This commit is contained in:
Chris Rebert 2014-02-18 13:35:50 -08:00
parent 7d2d219560
commit 09cd07f3e1

View File

@ -171,9 +171,9 @@ def NS(domain, resolve=True, nameserver=None):
if resolve:
ret = []
for ns in cmd['stdout'].split('\n'):
for a in A(ns, nameserver):
ret.append(a)
for ns_host in cmd['stdout'].split('\n'):
for ip_addr in A(ns_host, nameserver):
ret.append(ip_addr)
return ret
return cmd['stdout'].split('\n')