diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-15 19:40:15 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-15 19:40:15 +0000 |
commit | 399644e47874bff147afb19c89228901ac39340e (patch) | |
tree | 1c4c0b733f4c16b5783b41bebb19194a9ef62ad1 /man4/tty.4 | |
parent | Initial commit. (diff) | |
download | manpages-399644e47874bff147afb19c89228901ac39340e.tar.xz manpages-399644e47874bff147afb19c89228901ac39340e.zip |
Adding upstream version 6.05.01.upstream/6.05.01
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'man4/tty.4')
-rw-r--r-- | man4/tty.4 | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/man4/tty.4 b/man4/tty.4 new file mode 100644 index 0000000..1493e87 --- /dev/null +++ b/man4/tty.4 @@ -0,0 +1,67 @@ +.\" Copyright (c) 1993 Michael Haardt (michael@moria.de), +.\" Fri Apr 2 11:32:09 MET DST 1993 +.\" +.\" SPDX-License-Identifier: GPL-2.0-or-later +.\" +.\" Modified 1993-07-24 by Rik Faith (faith@cs.unc.edu) +.\" Modified 2003-04-07 by Michael Kerrisk +.\" +.TH tty 4 2022-10-30 "Linux man-pages 6.05.01" +.SH NAME +tty \- controlling terminal +.SH DESCRIPTION +The file +.I /dev/tty +is a character file with major number 5 and +minor number 0, usually with mode 0666 and ownership root:tty. +It is a synonym for the controlling terminal of a process, if any. +.PP +In addition to the +.BR ioctl (2) +requests supported by the device that +.B tty +refers to, the +.BR ioctl (2) +request +.B TIOCNOTTY +is supported. +.SS TIOCNOTTY +Detach the calling process from its controlling terminal. +.PP +If the process is the session leader, +then +.B SIGHUP +and +.B SIGCONT +signals are sent to the foreground process group +and all processes in the current session lose their controlling tty. +.PP +This +.BR ioctl (2) +call works only on file descriptors connected +to +.IR /dev/tty . +It is used by daemon processes when they are invoked +by a user at a terminal. +The process attempts to open +.IR /dev/tty . +If the open succeeds, it +detaches itself from the terminal by using +.BR TIOCNOTTY , +while if the +open fails, it is obviously not attached to a terminal and does not need +to detach itself. +.SH FILES +.I /dev/tty +.SH SEE ALSO +.BR chown (1), +.BR mknod (1), +.BR ioctl (2), +.BR ioctl_console (2), +.BR ioctl_tty (2), +.BR termios (3), +.BR ttyS (4), +.BR vcs (4), +.BR pty (7), +.BR agetty (8), +.BR mingetty (8) |