fclose

Close a file.

int fclose (FILE * stream);

Required Header
<stdio.h>

Return Value

This function returns 0 if the stream is successfully closed. -1 indicates an error.

Parameters

stream

  The pointer to the open FILE structure

Remarks

The fclose function closes the file specified by stream.

Stream I/O Routines

See Also    _fcloseall, _fdopen, fflush, fopen, freopen