in reply to Re: Telnet session disconnect testing
in thread Telnet session disconnect testing

arkturuz,

Not quite sure I understand your comment regarding the subroutines... I am not that great on Perl but thanks for the input. The problem with your suggestion is that I have provided others with this program to use http://simplesmdr.sourceforge.net so to hardcode a reboot time is not really an option here. Will look into the sleep() option though, thanks.
  • Comment on Re^2: Telnet session disconnect testing

Replies are listed 'Best First'.
Re^3: Telnet session disconnect testing
by arkturuz (Curate) on Jan 13, 2010 at 20:02 UTC
    Not quite sure I understand your comment regarding the subroutines

    Usually, you define your functions once, and rarely put them inside the loops (unless there's some tricky busines going on - like constantly defining new subroutines for some specific tasks). Nevertheless, if it's okay with you, and the program works as expected, then there's no problem. Although it's better for readabilly, maintenance, logic of the program, easier debugging, to do otherwise.

      Ok I see what you mean now, the for loop needs to be closed after the while loop closes.

      Made the change and everything works as before... not sure if this will resolved the problem with the link drop/reconnect issue though.