feof function — Tests for end-of-file
int feof(FILE* stream)
The feof function returns true (nonzero) if stream is positioned at the end-of-file, or false (0) otherwise.
feof
stream
0
clearerr function, ferror function