mirror of
https://github.com/percona/percona-toolkit.git
synced 2025-12-22 03:00:29 +08:00
Debug hack for ReadKeyMini::cooked().
This commit is contained in:
@@ -100,12 +100,14 @@ my %modes = (
|
|||||||
$term->setcc( VTIME, 1 );
|
$term->setcc( VTIME, 1 );
|
||||||
$term->setattr( $fd_stdin, TCSANOW );
|
$term->setattr( $fd_stdin, TCSANOW );
|
||||||
}
|
}
|
||||||
|
use Data::Dumper;
|
||||||
sub cooked {
|
sub cooked {
|
||||||
$term->setlflag($oterm);
|
$term->setlflag($oterm);
|
||||||
$term->setcc( VTIME, 0 );
|
$term->setcc( VTIME, 0 );
|
||||||
$term->setattr( $fd_stdin, TCSANOW );
|
$term->setattr( $fd_stdin, TCSANOW );
|
||||||
unless ( $PerconaTest::DONT_RESTORE_STDIN ) {
|
unless ( $PerconaTest::DONT_RESTORE_STDIN ) {
|
||||||
|
warn Dumper($fd_stdin);
|
||||||
|
warn Dumper($flags);
|
||||||
fcntl(STDIN, F_SETFL, $flags)
|
fcntl(STDIN, F_SETFL, $flags)
|
||||||
or warn "can't fcntl F_SETFL: $!";
|
or warn "can't fcntl F_SETFL: $!";
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user