The error-status flags store the information on the status of a file that is being currently used. The current state of the I/O system is held in an integer, in which the following flags are encoded:
Name |
Meaning |
eofbit |
1 when end-of-file is encountered, 0 otherwise. |
failbit |
1 when non-fatal I/O error has occurred, 0 otherwise. |
badbit |
1 when fatal I/O error has occurred, 0 otherwise. |
goodbit |
0 value |