stty Invalid argument

Tom Sanders tom at tcom.stc.co.uk
Thu Oct 26 18:43:42 AEST 1989


In article <1845 at bute.tcom.stc.co.uk> tom at tcom.stc.co.uk I wrote:
#Unix System V, Release 3.1
#--------------------------
#
#I am trying to write a shell script which will set up a set of tty
#options and exec a process.  Simple enough, I thought, but I get
#the error message:
#
#  stty: : Invalid argument
#
#Briefly, the problem has been traced to a number of options on the stty
#command.  For example,
#
#  stty igncr < /dev/tty6
#
#will produce the error message.  However,
#
#  stty -igncr < /dev/tty6
#
#is OK!!   Other options which behave this way are isig, icanon, olcuc
#and more.  The negative form is OK, the positive form not.  If the
#printer scheduler interface scripts can do it, why cant I?
#
#Any info gratefully received.

After a stunning response (0 follow-ups, 0 replies :-)) I discovered with
a little help that the options which were failing are implemented by a
module in the Stream sitting on the tty driver.  Until that module has been
pushed on to the Stream (with ioctl) only the hardware related options are
supported, things like character mapping and signal handling are not.

When opening a tty device not used by the system for logins, the module
is not present.  Just thought you might like to know...

Regards,
Tom
-- 
Tom Sanders  <tom at tcom.stc.co.uk>
             STC Telecomms, Oakleigh Rd South, London N11 1HB UK.



More information about the Comp.unix.questions mailing list