Gets the error status of a file, then clears it.
Each file has an error flag that gets set when there is an I/O error on
the file. Typically, once this flag is set, you can no longer do I/O on
the file, even if the error is a recoverable one.
fclearerr() clears the
file’s error flag, so you can attempt to continue using it.