No cache version.

Caching disabled. Default setting for this page:enabled (code LNG204)
If the display is too slow, you can disable the user mode to view the cached version.

Fermeture d'un fichier (fclose)

Syntaxe fclose


#include <stdio.h>

/* Suite du code ... */

int fclose(FILE *flux);

/* Suite du code ... */

Remarque fclose

Cette fonction ferme le fichier flux désigné, après avoir vidé le tampon qui lui est associé.
De plus, toutes les ressources nécessitées par le fichier sont libérées, dont les données de pointeurs de fichiers.

Valeur retournée par fclose

Elle retourne 0 si elle réussit, dans le cas contraire elle retourne EOF.

English translation

You have asked to visit this site in English. For now, only the interface is translated, but not all the content yet.

If you want to help me in translations, your contribution is welcome. All you need to do is register on the site, and send me a message asking me to add you to the group of translators, which will give you the opportunity to translate the pages you want. A link at the bottom of each translated page indicates that you are the translator, and has a link to your profile.

Thank you in advance.

Document created the 19/03/2002, last modified the 26/10/2018
Source of the printed document:https://www.gaudry.be/en/c-fclose.html

The infobrol is a personal site whose content is my sole responsibility. The text is available under CreativeCommons license (BY-NC-SA). More info on the terms of use and the author.