Question discussion

fflush (NULL) flushes all __________

164383Medium 1 reply 1,334 views

Discussion 1

0
CCommunity
Syntax:

#include

int fflush(FILE *stream);

If stream is associated with a file opened for writing, a call to fflush( ) causes the contents of the output buffer to be physically written to the file. The file remains open.

A return value of zero indicates success; EOF indicates that a write error has occurred.

All buffers are automatically flushed upon normal termination of the program or when they are full. Also, closing a file flushes its buffer.