home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!charon.amdahl.com!pacbell.com!ames!sun-barr!cs.utexas.edu!ut-emx!ccwf.cc.utexas.edu
- From: ifai645@ccwf.cc.utexas.edu (Paul C. Janzen)
- Newsgroups: comp.os.linux
- Subject: Re: ioctl()
- Keywords: ioctl(), TIOCSETP, TIOCGETP, ICANNON, CBREAK
- Message-ID: <83063@ut-emx.uucp>
- Date: 5 Nov 92 04:43:16 GMT
- References: <1992Nov3.070008.29001@news2.cis.umn.edu> <Bx7uAo.IB7@lysator.liu.se>
- Sender: news@ut-emx.uucp
- Organization: The University of Texas at Austin, Austin TX
- Lines: 31
-
- In article <Bx7uAo.IB7@lysator.liu.se> aronsson@lysator.liu.se (Lars Aronsson) writes:
- >lash0002@student.tc.umn.edu (tim) writes:
- >>i'm looking for are TIOCGETP, TIOCSETP, ICANNON or CBREAK, and
- >>TIOCGLTC.
-
- >TIOCGETP/TIOCSETP are not supported in LINUX. They might be standard,
- >but I don't think they are POSIX. Instead, use TCGETA/TCSETA to
- >read/set terminal driver parameters.
- >
- >Most free software packages that I have seen have a large #ifdef
- >surrounding the use of TIOCGETP/TIOSETP with TCGETA/TCSETA appearing
- >in the #else branch. When you find this, you are lucky. Just use the
- >-D or -U options to gcc when you compile, or edit "config.h" (or
- >whatever that file might be called) to #define the right token.
-
- The Posix Way involves no ioctl's. It uses
-
- #include <termios.h>
- #include <unistd.h>
-
- int tcgetattr(int fildes, struct termios *tp); and
- int tcsetattr(int fildes, int options, const struct termios *tp);
-
- instead.
-
- Is the behavior of TIOCGETP/friends the same as TCGETA/friends?
-
- ------------------------------------------------------------------------
- Paul C. Janzen There is a green, multi-legged creature
- ifai645@ccwf.cc.utexas.edu crawling on your shoulder.
- ------------------------------------------------------------------------
-