Lines Matching defs:localhost
1479 req.host != 'localhost'):
1481 raise URLError("file:// scheme is supported only on localhost")
1485 # names for the localhost
1491 socket.gethostbyname_ex('localhost')[2] +
1494 FileHandler.names = (socket.gethostbyname('localhost'),)
2002 if url[:2] == '//' and url[2:3] != '/' and url[2:12].lower() != 'localhost/':
2003 raise ValueError("file:// scheme is supported only on localhost")
2030 and socket.gethostbyname(host) in ((localhost(),) + thishost())):
2361 def localhost():
2362 """Return the IP address of the magic hostname 'localhost'."""
2365 _localhost = socket.gethostbyname('localhost')
2376 _thishost = tuple(socket.gethostbyname_ex('localhost')[2])
2759 # '<local>' string by the localhost entry and the corresponding