1
0
mirror of https://github.com/GNS3/gns3-server synced 2024-12-26 16:58:28 +00:00

Fixes too many arguments to socket.getaddrinfo()

This commit is contained in:
grossmj 2015-06-07 09:25:54 -06:00
parent 81e56e035b
commit 81d417a2b3
2 changed files with 2 additions and 2 deletions

View File

@ -381,7 +381,7 @@ class Dynamips(BaseManager):
rhost = nio_settings["rhost"] rhost = nio_settings["rhost"]
rport = nio_settings["rport"] rport = nio_settings["rport"]
try: try:
info = socket.getaddrinfo(rhost, rport, 0, socket.AF_UNSPEC, socket.SOCK_DGRAM, 0, socket.AI_PASSIVE) info = socket.getaddrinfo(rhost, rport, socket.AF_UNSPEC, socket.SOCK_DGRAM, 0, socket.AI_PASSIVE)
if not info: if not info:
raise DynamipsError("getaddrinfo returns an empty list on {}:{}".format(rhost, rport)) raise DynamipsError("getaddrinfo returns an empty list on {}:{}".format(rhost, rport))
for res in info: for res in info:

View File

@ -356,7 +356,7 @@ class TelnetServer(Console):
def __enter__(self): def __enter__(self):
# Open a socket and start listening # Open a socket and start listening
info = socket.getaddrinfo(self.addr, self.port, 0, socket.AF_UNSPEC, socket.SOCK_STREAM, 0, socket.AI_PASSIVE) info = socket.getaddrinfo(self.addr, self.port, socket.AF_UNSPEC, socket.SOCK_STREAM, 0, socket.AI_PASSIVE)
if not info: if not info:
raise TelnetServerError("getaddrinfo returns an empty list on {}:{}".format(self.addr, self.port)) raise TelnetServerError("getaddrinfo returns an empty list on {}:{}".format(self.addr, self.port))
for res in info: for res in info: