diff options
| author | 1996-01-05 18:02:24 +0000 | |
|---|---|---|
| committer | 1996-01-05 18:02:24 +0000 | |
| commit | cf26daa9825767937780abb26d27a8d8c2461c5f (patch) | |
| tree | 1418ec35269f41930d61c2e0e165764ff2018e12 | |
| parent | fix, and handle openbsd case too (diff) | |
| download | wireguard-openbsd-cf26daa9825767937780abb26d27a8d8c2461c5f.tar.xz wireguard-openbsd-cf26daa9825767937780abb26d27a8d8c2461c5f.zip | |
Add support for ostart and ostop
| -rw-r--r-- | bin/stty/key.c | 20 | ||||
| -rw-r--r-- | bin/stty/stty.1 | 19 |
2 files changed, 38 insertions, 1 deletions
diff --git a/bin/stty/key.c b/bin/stty/key.c index 956c5528b0e..2758fd399ba 100644 --- a/bin/stty/key.c +++ b/bin/stty/key.c @@ -67,6 +67,8 @@ void f_rows __P((struct info *)); void f_sane __P((struct info *)); void f_size __P((struct info *)); void f_speed __P((struct info *)); +void f_ostart __P((struct info *)); +void f_ostop __P((struct info *)); void f_tty __P((struct info *)); __END_DECLS @@ -90,6 +92,8 @@ static struct key { { "nl", f_nl, F_OFFOK }, { "old", f_tty, 0 }, { "ospeed", f_ospeed, F_NEEDARG }, + { "ostart", f_ostart, 0 }, + { "ostop", f_ostop, 0 }, { "raw", f_raw, F_OFFOK }, { "rows", f_rows, F_NEEDARG }, { "sane", f_sane, 0 }, @@ -304,3 +308,19 @@ f_tty(ip) if (ioctl(0, TIOCSETD, &tmp) < 0) err(1, "TIOCSETD"); } + +void +f_ostart(ip) + struct info *ip; +{ + if (ioctl (0, TIOCSTART) < 0) + err(1, "TIOCSTART"); +} + +void +f_ostop(ip) + struct info *ip; +{ + if (ioctl (0, TIOCSTOP) < 0) + err(1, "TIOCSTOP"); +} diff --git a/bin/stty/stty.1 b/bin/stty/stty.1 index 3d863a1026a..9cd1f3906c8 100644 --- a/bin/stty/stty.1 +++ b/bin/stty/stty.1 @@ -568,6 +568,22 @@ Same as the control character Same as the control character .Cm reprint . .El +.Ss Control operations: +.Pp +These operations are not modes, but rather commands to be performed by +the tty layer. +.Bl -tag -width Fl +.It Cm ostart +Performs a "start output" operation, as normally done by an +incoming START character when +.Cm ixon +is set. +.It Cm ostop +Performs a "stop output" operation, as normally done by an +incoming STOP character when +.Cm ixon +is set. +.El .Pp The .Nm stty @@ -584,4 +600,5 @@ compatible. The flags and .Fl f are -extensions to the standard. +extensions to the standard, as are the operands mentioned in the control +operations section. |
