The IP is a valid Id but doesnt lead to anything so the socket cant connect to it.
But it just gets stuck when calling socket.connect(), providing the timeout=1 doesnt do anything either.
Adding a try ... catch also doesnt work because it never resolves the socket.connect()
I have these simple lines:
The IP is a valid Id but doesnt lead to anything so the socket cant connect to it. But it just gets stuck when calling
socket.connect()
, providing thetimeout=1
doesnt do anything either. Adding atry ... catch
also doesnt work because it never resolves thesocket.connect()