in reply to TCP Server Exits Loop and Crashes with error
As afoken said, check if your io commands succeed. Alternatively you might check $sock->error (see IO::Handle, IO::Socket objects inherit the methods from IO::Handle).
I'm a little confused by your description of the problem: Did you say that your script works correctly and prints no error message if you send a message that doesn't result in an ssh attempt, for example if the port number is not in your hash ?
|
|---|