FCLOSE(3S)	    UNIX Programmer's Manual	       FCLOSE(3S)


NAME
     fclose, fflush - close or flush a stream

SYNOPSIS
     #include <stdio.h>

     fclose(stream)
     FILE *stream;

     fflush(stream)
     FILE *stream;

DESCRIPTION
     Fclose causes any buffers for the named stream to be emp-
     tied, and the file to be closed.  Buffers allocated by the
     standard input/output system are freed.

     Fclose is performed automatically upon calling exit(3).

     Fflush causes any buffered data for the named output stream
     to be written to that file.  The stream remains open.

SEE ALSO
     close(2), fopen(3S), setbuf(3S)

DIAGNOSTICS
     These routines return EOF if stream is not associated with
     an output file, or if buffered data cannot be transferred to
     that file.


Printed 11/26/99	  May 15, 1985				1


 
Generated: 2016-12-26
Generated by man2html V0.25
page hit count: 1372
Valid CSS Valid XHTML 1.0 Strict