added check for eof for ZlibRStream