1FERROR(3S) FERROR(3S)
2
3
4
6 ferror, feof, clearerr, fileno - stream status inquiries
7
9 #include <stdio.h>
10
11 feof(stream)
12 FILE *stream;
13
14 ferror(stream)
15 FILE *stream
16
17 clearerr(stream)
18 FILE *stream
19
20 fileno(stream)
21 FILE *stream;
22
24 Feof returns non-zero when end of file is read on the named input
25 stream, otherwise zero. Unless cleared by clearerr, the end-of-file
26 indication lasts until the stream is closed.
27
28 Ferror returns non-zero when an error has occurred reading or writing
29 the named stream, otherwise zero. Unless cleared by clearerr, the
30 error indication lasts until the stream is closed.
31
32 Clearerr resets the error and end-of-file indicators on the named
33 stream.
34
35 Fileno returns the integer file descriptor associated with the stream,
36 see open(2).
37
38 Currently all of these functions are implemented as macros; they cannot
39 be redeclared.
40
42 fopen(3S), open(2)
43
44
45
464th Berkeley Distribution May 14, 1986 FERROR(3S)