FERROR(3S)
NAME
ferror, feof, clearerr, fileno − stream status inquiries
USAGE
#include <stdio.h>
feof(stream) FILE *stream;
ferror(stream) FILE *stream;
clearerr(stream) FILE *stream;
fileno(stream) FILE *stream;
DESCRIPTION
Feof returns a non-zero indicator when end of file (EOF) is read on the input stream; otherwise, it returns zero.
Ferror returns non-zero when an error has occurred in reading or writing on the named stream; if no error has occurred, it returns zero.
Clearerr resets the error indication on the named stream. Unless cleared by clearerr, the error indication lasts until the stream is closed.
Fileno returns the integer file descriptor associated with the stream; see open(2).
These functions are implemented as macros; they cannot be redeclared.