TTYNAME(S) XENIX System V TTYNAME(S)
Name
ttyname, isatty - Finds the name of a terminal.
Syntax
char *ttyname (fildes)
int isatty (fildes)
int fildes;
Description
ttyname returns a pointer to the null-terminated pathname of
the terminal device associated with file descriptor fildes.
isatty returns 1 if fildes is associated with a terminal
device, 0 otherwise.
Files
/dev/*
Diagnostics
ttyname returns a null pointer (0) if fildes does not
describe a terminal device in directory /dev.
Notes
The return value points to static data whose content is
overwritten by each call.
Page 1 (printed 8/7/87)