You copied the Doc URL to your clipboard.

4.39 _sys_istty()

Declared in rt_sys.h, the _sys_istty() function determines whether a file handle is attached to an interactive device.

Syntax

int _sys_istty(FILEHANDLE fh);

Usage

The ARM libraries call __sys_istty() to determine whether a file handle (that is being used for an output file stream) is attached to an interactive device.

For file streams that are attached to interactive devices, the ARM library:

  • Provides unbuffered behavior by default, in the absence of a call to setbuf() or setvbuf().
  • Prohibits seeking.

Restriction

stdin, stdout, and stderr, are interactive devices, but are line-buffered at program startup.

Returns

The return value is one of the following values:

0
fh is not attached to an interactive device.
1
fh is attached to an interactive device.
other
An error occurred.
Was this page helpful? Yes No