more work
This commit is contained in:
parent
5fd2f3d6ee
commit
9c0bab297e
2 changed files with 28 additions and 24 deletions
|
@ -298,6 +298,8 @@ class DNSResolver(object):
|
|||
callback((hostname, ip), None)
|
||||
if self._hostname_to_cb.__contains__(hostname):
|
||||
del self._hostname_to_cb[hostname]
|
||||
if self._hostname_status.__contains__(hostname):
|
||||
del self._hostname_status[hostname]
|
||||
|
||||
def handle_events(self, events):
|
||||
for sock, fd, event in events:
|
||||
|
@ -328,6 +330,8 @@ class DNSResolver(object):
|
|||
arr.remove(callback)
|
||||
if not arr:
|
||||
del self._hostname_to_cb[hostname]
|
||||
if self._hostname_status.__contains__(hostname):
|
||||
del self._hostname_status[hostname]
|
||||
|
||||
def _send_req(self, hostname, qtype):
|
||||
logging.debug('resolving %s with type %d using server %s', hostname,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue