Add code for setting/clearing/reporting the
authorPaul Borman <borman@ucbvax.Berkeley.EDU>
Sat, 15 Sep 1990 03:33:35 +0000 (19:33 -0800)
committerPaul Borman <borman@ucbvax.Berkeley.EDU>
Sat, 15 Sep 1990 03:33:35 +0000 (19:33 -0800)
EXTPROC and NOKERNINFO bits.

SCCS-vsn: bin/stty/stty.c 5.18

usr/src/bin/stty/stty.c

index acc40f0..cccfa6c 100644 (file)
@@ -11,7 +11,7 @@ char copyright[] =
 #endif not lint
 
 #ifndef lint
 #endif not lint
 
 #ifndef lint
-static char sccsid[] = "@(#)stty.c     5.17 (Berkeley) %G%";
+static char sccsid[] = "@(#)stty.c     5.18 (Berkeley) %G%";
 #endif not lint
 
 /*
 #endif not lint
 
 /*
@@ -170,6 +170,10 @@ struct modes lmodes[] = {
        "-crt",         ECHOK, ECHOE|ECHOKE|ECHOCTL,
        "newcrt",       ECHOE|ECHOKE|ECHOCTL, ECHOK|ECHOPRT,
        "-newcrt",      ECHOK, ECHOE|ECHOKE|ECHOCTL, 
        "-crt",         ECHOK, ECHOE|ECHOKE|ECHOCTL,
        "newcrt",       ECHOE|ECHOKE|ECHOCTL, ECHOK|ECHOPRT,
        "-newcrt",      ECHOK, ECHOE|ECHOKE|ECHOCTL, 
+       "nokerninfo",   NOKERNINFO, 0,
+       "-nokerninfo",  0, NOKERNINFO,
+       "kerninfo",     0, NOKERNINFO,
+       "-kerninfo",    NOKERNINFO, 0,
        0
 };
 
        0
 };
 
@@ -214,6 +218,7 @@ int ldisc;
 int dodisc;
 int debug = 0;
 int trace, dotrace;
 int dodisc;
 int debug = 0;
 int trace, dotrace;
+int extproc;
 
 #define OUT    stdout          /* informational output stream */
 #define ERR    stderr          /* error message stream */
 
 #define OUT    stdout          /* informational output stream */
 #define ERR    stderr          /* error message stream */
@@ -350,6 +355,13 @@ main(argc, argv)
                        put("%d %d\n", win.ws_row, win.ws_col);
                        exit(0);
                }
                        put("%d %d\n", win.ws_row, win.ws_col);
                        exit(0);
                }
+               if (eq("extrpc", *argv) || eq("-extproc", *argv)) {
+                       if (**argv == '-')
+                               extproc = 0;
+                       else
+                               extproc = 1;
+                       ioctl(ctl, TIOCEXT, &extproc);
+               }
                if (eq("speed", *argv)) {
                        put("%d\n", cfgetospeed(&t));
                        exit(0);
                if (eq("speed", *argv)) {
                        put("%d\n", cfgetospeed(&t));
                        exit(0);
@@ -558,6 +570,8 @@ prmode(tp, ldisc, fmt)
        lput("-mdmbuf ",MDMBUF, 0);
        lput("-flusho ",FLUSHO, 0);
        lput("-pendin ",PENDIN, 0);
        lput("-mdmbuf ",MDMBUF, 0);
        lput("-flusho ",FLUSHO, 0);
        lput("-pendin ",PENDIN, 0);
+       lput("-nokerninfo ",NOKERNINFO, 0);
+       lput("-extproc ",EXTPROC, 0);
        /*
         * input flags
         */
        /*
         * input flags
         */