A call to ferror continues to return a nonzero integer until the file is closed or until clearerr is called.