Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

init(8)

vhangup(2)

Name

vhangup − virtually hang up the current control terminal

Syntax

vhangup()

Description

The vhangup system call initializes a terminal line. For example, the init command uses vhangup to ensure that the previous user’s processes cannot access the terminal anymore.

First, vhangup searches the system tables for references to the current terminal (the control terminal of the invoking process) and revokes access permissions on each instance of the terminal that it finds.

The vhangup system call also removes all references to the inode that corresponds to the control terminal. The vhangup system call then invokes the kernel’s device close routine to turn the terminal off. Finally, vhangup sends a hangup signal (SIGHUP) to the process group of the control terminal.  For further information, see tty() for a description of process groups.

When vhangup finishes, a terminal line is initialized; no other processes refer to this line. The only way for other processes to access the control terminal is through the special file, /dev/tty. All other requests will yield I/O errors (EBADF).

See Also

init(8)

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026