Writes out any buffered information for the specified file.
#include <stdio.h> int fflush (FILE *file_ptr);
The fflush function flushes the DEC C RTL buffers. However, RMS has its own buffers. The fflush function does not guarantee that the file will be written to disk. (See the description of fsync for a way to flush buffers to disk.)
If the file pointed to by file_ptr was opened in record mode and if there is unwritten data in the buffer, then fflush always generates a record.
0 | Indicates that the operation is successful. |
EOF | Indicates that the buffered data cannot be written to the file, or that the file control block is not associated with an output file. |