diff options
Diffstat (limited to 'src/user/lib/include')
-rw-r--r-- | src/user/lib/include/bits/file.h | 10 | ||||
-rw-r--r-- | src/user/lib/include/stdio.h | 6 |
2 files changed, 6 insertions, 10 deletions
diff --git a/src/user/lib/include/bits/file.h b/src/user/lib/include/bits/file.h index e50d402..63a31c4 100644 --- a/src/user/lib/include/bits/file.h +++ b/src/user/lib/include/bits/file.h @@ -1,10 +1,2 @@ #pragma once -#include <stdbool.h> -// TODO make opaque -struct FILE { - int fd; - int pos; - bool eof; - bool error; -}; -typedef struct FILE FILE; +typedef struct _LIBC_FILE FILE; diff --git a/src/user/lib/include/stdio.h b/src/user/lib/include/stdio.h index 2f0746f..b8de85d 100644 --- a/src/user/lib/include/stdio.h +++ b/src/user/lib/include/stdio.h @@ -16,6 +16,10 @@ FILE *fopen(const char *path, const char *mode); FILE *freopen(const char *path, const char *mode, FILE *); FILE *fdopen(int fd, const char *mode); FILE *file_clone(const FILE *); +int fclose(FILE *); + size_t fread(void *restrict ptr, size_t size, size_t nitems, FILE *restrict); size_t fwrite(const void *restrict ptr, size_t size, size_t nitems, FILE *restrict); -int fclose(FILE *); + +int feof(FILE *); +int ferror(FILE *); |