diff options
Diffstat (limited to 'usr/klibc/stdio/rewind.c')
-rw-r--r-- | usr/klibc/stdio/rewind.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/usr/klibc/stdio/rewind.c b/usr/klibc/stdio/rewind.c new file mode 100644 index 0000000..fb7cd5a --- /dev/null +++ b/usr/klibc/stdio/rewind.c @@ -0,0 +1,8 @@ +#include <stdio.h> +#include <stdbool.h> + +void rewind(FILE *f) +{ + if (!fseek(f, 0, SEEK_SET)) + f->_IO_error = false; +} |