summaryrefslogtreecommitdiff
path: root/src/user/lib/include/stdio.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/user/lib/include/stdio.h')
-rw-r--r--src/user/lib/include/stdio.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/user/lib/include/stdio.h b/src/user/lib/include/stdio.h
index 9d6921a..2f0746f 100644
--- a/src/user/lib/include/stdio.h
+++ b/src/user/lib/include/stdio.h
@@ -2,6 +2,8 @@
#include <bits/file.h>
#include <stddef.h>
+#define EOF (-1)
+
int printf(const char *fmt, ...);
int snprintf(char *str, size_t len, const char *fmt, ...);
@@ -11,9 +13,9 @@ int _klogf(const char *fmt, ...); // for kernel debugging only
extern FILE *const stdin, *const stdout;
FILE *fopen(const char *path, const char *mode);
-FILE *freopen(const char *path, const char *mode, FILE*);
+FILE *freopen(const char *path, const char *mode, FILE *);
FILE *fdopen(int fd, const char *mode);
-FILE *file_clone(const FILE*);
-int file_read(FILE*, char *buf, size_t len);
-int file_write(FILE*, const char *buf, size_t len);
-void file_close(FILE*);
+FILE *file_clone(const 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 *);