Debian Codegraph @

upstream/debian-trixie/man2/TIOCSETD.2const

raw
1 .\" Copyright 2002, Walter Harms <[email protected]>
2 .\" Copyright 2002, Andries Brouwer <[email protected]>
3 .\" Copyright 2024, Alejandro Colomar <[email protected]>
4 .\"
5 .\" SPDX-License-Identifier: GPL-1.0-or-later
6 .\"
7 .TH TIOCSETD 2const 2024-06-13 "Linux man-pages 6.9.1"
8 .SH NAME
9 TIOCGETD,
10 TIOCSETD
11 \-
12 get or set the line discipline of the terminal
13 .SH LIBRARY
14 Standard C library
15 .RI ( libc ", " \-lc )
16 .SH SYNOPSIS
17 .nf
18 .BR "#include <asm/termbits.h>" " /* Definition of " TIOC*ETD " constants */"
19 .B #include <sys/ioctl.h>
20 .P
21 .BI "int ioctl(int " fd ", TIOCGETD, int *" argp );
22 .BI "int ioctl(int " fd ", TIOCSETD, const int *" argp );
23 .fi
24 .SH DESCRIPTION
25 .TP
26 .B TIOCGETD
27 Get the line discipline of the terminal.
28 .TP
29 .B TIOCSETD
30 Set the line discipline of the terminal.
31 .SH RETURN VALUE
32 On success,
33 0 is returned.
34 On error,
35 \-1 is returned, and
36 .I errno
37 is set to indicate the error.
38 .SH SEE ALSO
39 .BR ioctl (2),
40 .BR ioctl_tty (2)