This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: simple c 's printf problem in mandrake8.0
- From: eric <fsshl at centurytel dot net>
- To: Stephano Mariani <sk dot ml at btinternet dot com>
- Cc: gcc-help at gcc dot gnu dot org
- Date: Sun, 30 Dec 2001 07:30:46 -0500
- Subject: Re: simple c 's printf problem in mandrake8.0
- Organization: onlineexchange
- References: <000301c19116$d7a55810$b500a8c0@sknet01>
Dear Stephano:
I tried to put what you suggest fflush(stdout), either before or after
printf("hello World") , it still not print in bash shell.
or I type fflush(stdout) in my bash command line, it response command
not found.
Would you mind to explain a little bit more,
> It's always a good idea to flush before you close a stream
on redhat 7.1 , it works(although whether it is bash or any other
shell), so far as I know only mandrake8 is not work.
sincer eric, http://www.ezinfocenter.com/4436786
Stephano Mariani wrote:
>
> The cause is a bug in the libc on mandrake 8.x and redhat 7.x
> In order to explicitly flush the buffer just use the fflush on the
> stream you want to flush. E.g. fflush(stdout) in this case.
>
> It's always a good idea to flush before you close a stream.
>
> Stephano Mariani
>