Everything

rewind


Shifts the current read/write position in a stream input/output file to the beginning of the file.

[Format]

#include <stdio.h>

void rewind (FILE *fp);

[Parameters]

fp File pointer

[Remarks]

The rewind function shifts the current read/write position in the stream input/output file indicated by file pointer fp, to the beginning of the file.

The rewind function clears the end-of-file indicator and error indicator for the file.

Note that calling the rewind function cancels the effect of the ungetc function.