stty: standard input: Inappropriate ioctl for device
I think the problem is you are reading from a redirected STDIN (because you <file.txt)
$ perl -e 'system("stty -echo");' </tmp/foo
stty: standard input: Inappropriate ioctl for device
You should probably pass your file as a parameter to your script.
Can someone explain to me what stty does?
Try
$ stty echo < ~/tmp/some.file
stty: standard input: Inappropriate ioctl for device
so, stty
expects its standard input to be a terminal.
Therefore, if you run on your terminal
$ stty echo
you will receive no errors.
Related Topics
How to Rename a Shared Library to Avoid Same-Name Conflict
Need Some Advise to Begin Programming on Arm (With Linux) Platform
Controlling The Boot Screen on Linux Embedded App
File/Directory Permissions Trailing + ( Drwxr-Xr-X+ )
Reading Kernel Memory Using a Module
Sort a File Based on a Column in Another File
Linux + Find Word in File Under Directory But Quickly
How to Cancel Command in Grunt Shell
Specify CPU Frequency as a Kernel Cmd_Line Parameter of Linux on Boot
Linux Device Driver Unsafe Fxsave/Fxrstor Bug - Any Precedents
Reading Memory Pointed by Register with Gdb
Different Behavior of Which Command in Zsh and Bash
Mpc/Mpd on Linux: How to Play Local Wav File
How to Remove File with Special Characters
Linux Sockets: Zero-Copy Local, Tcp/Ip Remote