[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: probleme de fclose
Hate to be picky but..
I'm not certain if the poster knows English, and I certainly do not know
French, but at first glance this looks like a programming question. I know
we are all programmers here but still this is not the appropriate place
for questions like this. Try your favorite C++ mailing list or newsgroup.
HAND
James (who despises OOP in general and C++ in particular ;-)
On Fri, 23 Apr 1999, Tony Gibaud wrote:
> Salut,
> dans mon programme en C++,j'ai la routine suivante.
> le probleme est que mon compilateur n'accapte pas le fclose.
> j'ai les messages:
> /**********************************************
> -File_Flux was not declared in this scope
> -Warning : Ansi C++ forbids declaration 'fclose' with no type of storage
> class
> -int fclose redeclared as different kind of Symbol
> /**********************************************
> l'orsque je compilait cette fonction en C ça passait mais là !!!!
> Qqn connais t'il la raison de mon désespoire ?
>
> d'avance merci.
>
> tony.gibaud@horanet.fr
>
> Zipper
>
>
> ERREUR C_Serie :: LireNouvelleConfiguration(char* pcPathNomConfig,char*
> pcCom)
> {
> FILE* FILE_Flux;
> int iFluxCom;
> int iFin;
> unsigned char cChar;
>
> iFin=0;
>
> FILE_Flux=fopen(pcPathNomConfig,"w+");/*ouverture du fichier lecture
> ecriture création effacement*/
> if(FILE_Flux == NULL) return("ERREUR ouverture fichier nouvelle
> configuration");
> else{
> do
> {
> if( (read(iFluxCom,&cChar,1)==-1) )return("erreur de lecture");
> if( cChar==0x24 )iFin=1;
> else
> {
> if( (fprintf(FILE_Flux,"%c",cChar)) ==EOF)return("erreur
> d'ecriture dans le fichier");
> }
> }
> while(!iFin);
> }
> }
> fclose(FILE_Flux);/*fermeture du fichier de transfert*/
> }
>
+-----------------------------------------------------------------------------+
| James Curbo -- <jc108788@cyprus.hsu.edu> - <james@mousehole.sandwich.net> |
| computer science/math undergraduate - http://mousehole.sandwich.net/~james/ |
| Henderson State University Department of Mathematics and Computer Science |
+-----------------------------------------------------------------------------+