SocketConnect causes unrecoverable error on invalid address string

When trying to start a socket connection as a client using the SocketConnect command,
I ran into the issue that this command will cause an unrecoverable error on my system in case the address string is invalid. (I am currently running RobotWare 6.08.01)
From what I found out so far, an "invalid" IP address can be a malformed IP string, but apparently also IP addresses that are outside of the robot's subnet. Since the IP address I connect to is defined dynamically, I would like to be able to handle this issue in my program in case the address is invalid rather than just stopping everything.

Since its an unrecoverable error, I assume there is no option for error handling for me here. But is there a way to check, if a string represents a valid, reachable IP address before passing it to SocketConnect?




Tagged:

Comments

Sign In or Register to comment.