|This version of this document is no longer maintained. For the latest documentation, see http://www.qnx.com/developers/docs.|
Get the current terminal control settings
#include <termios.h> int tcgetattr( int fildes, struct termios *termios_p );
- The file descriptor associated with the terminal device.
- A pointer to a termios structure in which tcgetattr() can store the terminal's control attributes.
Use the -l c option to qcc to link against this library. This library is usually included automatically.
The tcgetattr() function gets the current terminal control settings for the opened device indicated by fildes, and stores the results in the structure pointed to by termios_p.
- An error occurred; errno is set.
- The fildes argument is invalid.
- The resource manager associated with fildes doesn't support this call.
- The fildes argument doesn't refer to a terminal device.
Chapter 7 of POSIX 1003.1