TIOCGLCKTRMIOS, TIOCSLCKTRMIOS - locking the termios structre
Contents
Caveats
Please note that structtermios from <asm/termbits.h> is different and incompatible with structtermios
from <termios.h>. These ioctl calls require structtermios from <asm/termbits.h>.
Description
The termios structure of a terminal can be locked. The lock is itself a termios structure, with nonzero
bits or fields indicating a locked value.
TIOCGLCKTRMIOS
Gets the locking status of the termios structure of the terminal.
TIOCSLCKTRMIOS
Sets the locking status of the termios structure of the terminal. Only a process with the
CAP_SYS_ADMIN capability can do this.
Errors
EPERM Insufficient permission.
Library
Standard C library (libc, -lc)
Name
TIOCGLCKTRMIOS, TIOCSLCKTRMIOS - locking the termios structre
Return Value
On success, 0 is returned. On error, -1 is returned, and errno is set to indicate the error.
See Also
ioctl(2), ioctl_tty(2), TCSETS(2const)
Linux man-pages 6.9.1 2024-06-13 TIOCSLCKTRMIOS(2const)
Synopsis
#include<asm/termbits.h> /* Definition of TIOC*CLKTRMIOS constants */
#include<sys/ioctl.h>intioctl(intfd,TIOCGLCKTRMIOS,structtermios*argp);intioctl(intfd,TIOCSLCKTRMIOS,conststructtermios*argp);#include<asm/termbits.h>structtermios;
