print reason if connection fails
This commit is contained in:
@@ -181,10 +181,10 @@ class TcpInterface(threading.Thread):
|
|||||||
s = socket.socket(res[0], socket.SOCK_STREAM)
|
s = socket.socket(res[0], socket.SOCK_STREAM)
|
||||||
s.connect(res[4])
|
s.connect(res[4])
|
||||||
return s
|
return s
|
||||||
except:
|
except BaseException as e:
|
||||||
continue
|
continue
|
||||||
else:
|
else:
|
||||||
print_error("failed to connect", self.host, self.port)
|
print_error("failed to connect", self.host, self.port, str(e))
|
||||||
|
|
||||||
|
|
||||||
def get_socket(self):
|
def get_socket(self):
|
||||||
|
|||||||
Reference in New Issue
Block a user