SYNOPSIS
#include <termios.h>
int tcsetattr(int fildes, int optional_actions, const struct termios *termios_p);
DESCRIPTION
The
- TCSANOW
-
The change occurs immediately.
- TCSADRAIN
-
The change occurs after all output written to the file descriptor has been transmitted. This action should be used when changing parameters that affect output.
- TCSAFLUSH
-
The change occurs after all output written to the file descriptor has been transmitted, and all input so far received but not read is discarded before the change is made.
The
The effect of
PARAMETERS
- fildes
-
Is a file descriptor that must refer to a terminal.
- optional_actions
-
An option that must be one of the following: TCSANOW, TCSADRAIN, TCSAFLUSH.
- termios_p
-
Points to a location in the termios structure.
RETURN VALUES
If successful,
- EBADF
-
The fildes parameter is not a valid file descriptor.
- EINTR
-
A signal interrupted the call.
- EINVAL
-
The optional_actions parameter is not a proper value, or an attempt was made to change an attribute represented in the termios structure to an unsupported value.
- ENOTTY
-
The file associated with fildes is not a terminal.
CONFORMANCE
POSIX.1 (1996).
MULTITHREAD SAFETY LEVEL
Async-signal-safe.
PORTING ISSUES
None.
AVAILABILITY
PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Professional Developers 64-Bit Edition
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition
SEE ALSO
- Functions:
ioctl() ,tcgetattr()
- Miscellaneous:
- struct termios
PTC MKS Toolkit 10.5 Documentation Build 40.