php_stream_eof() checks for an end-of-file condition on stream.
php_stream_eof() returns the 1 to indicate EOF, 0 if there is no EOF and -1 to indicate an error.