mirror of
https://github.com/GNS3/gns3-server
synced 2024-12-26 00:38:10 +00:00
Fixes too many arguments to socket.getaddrinfo()
This commit is contained in:
parent
81e56e035b
commit
81d417a2b3
@ -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:
|
||||||
|
@ -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:
|
||||||
|
Loading…
Reference in New Issue
Block a user