This is the mail archive of the mailing list for the Cygwin project. See the Cygwin home page for more information.
[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index] [Subject Index] [Author Index] [Thread Index]

Active Perl console access

I am trying to get this snippet of code working on my system. 
use Term::ReadKey;
use Fcntl;
#Set the FileHandles to TRUE

ReadMode 2;

print "\nEnter passwd: ";

$t = ReadLine 0;

chop $t;

print "\nYou entered $t\n";

My system is:
WinNT 4.0 SP4 
Active Perl 5.005.509
Connecting via sshd

When I try to run my code I get this error:
{jj-a@xena}~/perl/readpasswd: perl
GetConsoleMode failed, LastError=|6| at
d:\apps\perl\site\lib/Term/ line 247.

When I run it via a local bash shell, a cmd.exe shell, or a remote
Ataman Telnetd shell it works as expected.

Elsewhere in my code I need to use the Win32::AdminMisc module so a port
of perl is out (unless the Win32 modules run under cygnus perl this

Any ideas on how to pass console information from an sshd shell to perl?

Thanks in advance.

JJ Streicher-Bremer
NT Systems Administrator
Digital Island Inc.

Want to unsubscribe from this list?
Send a message to