david/ipxe
david
/
ipxe
Archived
1
0
Fork 0

[util] Disable automatic CR->LF conversion in serial-console utility

DUET (the EFI test environment) seems not to handle LF, so inhibit the
CR->LF conversion that the pty does for us by default.  This doesn't
affect operation of gPXE, which will happily accept either CR or LF.
This commit is contained in:
Michael Brown 2008-09-07 22:08:40 +01:00
parent 18aa0e79d2
commit 8223084afc
1 changed files with 2 additions and 2 deletions

View File

@ -224,8 +224,8 @@ if ( -t STDIN ) {
$restore_termios = POSIX::Termios->new;
$termios->getattr ( fileno(STDIN) );
$restore_termios->getattr ( fileno(STDIN) );
$termios->setlflag ( $termios->getlflag &
~(ICANON) & ~(ECHO) );
$termios->setlflag ( $termios->getlflag & ~(ICANON) & ~(ECHO) );
$termios->setiflag ( $termios->getiflag & ~(ICRNL) );
$termios->setattr ( fileno(STDIN), TCSANOW );
}