search for: gethostbyname_ex

Displaying 1 result from an estimated 1 matches for "gethostbyname_ex".

2012 May 02
1
Incomplete host name resolution
...have: [adrian at adrian projects]$ python Python 2.6.6 (r266:84292, Dec 7 2011, 20:48:22) [GCC 4.4.6 20110731 (Red Hat 4.4.6-3)] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import socket >>> socket.gethostbyname_ex('adrian') ('adrian', [], ['192.168.122.1']) >>> for a in socket.getaddrinfo('adrian', None, 0, 0, 0, socket.AI_CANONNAME) : ... print a ... (2, 1, 6, 'adrian', ('192.168.122.1', 0)) (2, 2, 17, '', ('192.168.122.1', 0)) (...