isatty()

tests if file descriptor is associated with terminal device 

Function


SYNOPSIS

#include <unistd.h>

int isatty(int fildes);


DESCRIPTION

The isatty() function tests whether the specified file descriptor is associated with a terminal device.


PARAMETERS

fildes 

Is the file descriptor to test.


RETURN VALUES

If the file descriptor fildes describes a terminal, isatty() returns a value of 1. If fildes is not a terminal, isatty() returns a value of zero, and sets errno to one of the following values:

ENOTTY 

The fildes parameter is not associated with a terminal.


CONFORMANCE

UNIX 98.


MULTITHREAD SAFETY LEVEL

MT-Safe.


PORTING ISSUES

None.


AVAILABILITY

PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Professional Developers 64-Bit Edition
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition


SEE ALSO

Functions:
ttyname(), ttyname_r()


PTC MKS Toolkit 10.4 Documentation Build 39.