in reply to Re: cls and perl
in thread cls and perl

Just a thought off the top of my head, because I'm not quite following the full flow of code that you are talking about...

Is it possible that STDIN is getting closed or redirected by the telnet/sftp code? You could check for this by testing whether STDIN is open to a tty at the start of mmenu.

if (-t STDIN) { # go on with normal operations } else { # complain and/or re-open to the tty }
DrWhy "If God had meant for us to think for ourselves he would have given us brains. Oh, wait..."