whois/whois.py
changeset 132 7666f0765fe4
parent 124 dfa8657bdefc
child 134 3ff7f09ea24a
equal deleted inserted replaced
131:193a62737030 132:7666f0765fe4
   124             s.close()
   124             s.close()
   125         except socket.error as socketerror:
   125         except socket.error as socketerror:
   126             print('Socket Error:', socketerror)
   126             print('Socket Error:', socketerror)
   127 
   127 
   128         nhost = None
   128         nhost = None
   129         response = response.decode('utf-8', errors='replace')
   129         response = response.decode('utf-8', 'replace')
   130         if 'with "=xxx"' in response:
   130         if 'with "=xxx"' in response:
   131             return self.whois(query, hostname, flags, True)
   131             return self.whois(query, hostname, flags, True)
   132         if flags & NICClient.WHOIS_RECURSE and nhost is None:
   132         if flags & NICClient.WHOIS_RECURSE and nhost is None:
   133             nhost = self.findwhois_server(response, hostname, query)
   133             nhost = self.findwhois_server(response, hostname, query)
   134         if nhost is not None:
   134         if nhost is not None: