.\"
.\" Modified 2000-07-22 by Nicolás Lichtmaier <nick@debian.org>
.\"
-.TH FCLOSE 3 2009-02-23 "GNU" "Linux Programmer's Manual"
+.TH FCLOSE 3 2015-01-22 "GNU" "Linux Programmer's Manual"
.SH NAME
fclose \- close a stream
.SH SYNOPSIS
.B #include <stdio.h>
.sp
-.BI "int fclose(FILE *" fp );
+.BI "int fclose(FILE *" stream );
.SH DESCRIPTION
The
.BR fclose ()
function flushes the stream pointed to by
-.I fp
+.I stream
(writing any buffered output data using
.BR fflush (3))
and closes the underlying file descriptor.
.TP
.B EBADF
The file descriptor underlying
-.I fp
+.I stream
is not valid.
.\" This error cannot occur unless you are mixing ANSI C stdio operations and
.\" low-level file operations on the same stream. If you do get this error,
.\" you must have closed the stream's low-level file descriptor using
-.\" something like close(fileno(fp)).
+.\" something like close(fileno(stream)).
.PP
The
.BR fclose ()
.SH NOTES
Note that
.BR fclose ()
-only flushes the user-space buffers provided by the
+flushes only the user-space buffers provided by the
C library.
To ensure that the data is physically stored
on disk the kernel buffers must be flushed too, for example, with
.BR fopen (3),
.BR setbuf (3)
.SH COLOPHON
-This page is part of release 3.64 of the Linux
+This page is part of release 3.79 of the Linux
.I man-pages
project.
A description of the project,
-and information about reporting bugs,
+information about reporting bugs,
+and the latest version of this page,
can be found at
\%http://www.kernel.org/doc/man\-pages/.