filebuf::close

Syntax

filebuf* close();

Remarks

This function flushes any waiting output, closes the file, and disconnects the file from the filebuf object. If an error occurs, the function returns NULL and leaves the filebuf object in a closed state. If there is no error, the function returns the address of the filebuf object and clears its error state.

See Also

filebuf::open