diff options
| author | Ada Christine <adachristine18@gmail.com> | 2026-05-26 21:32:27 +0000 |
|---|---|---|
| committer | Ada Christine <adachristine18@gmail.com> | 2026-05-26 21:32:27 +0000 |
| commit | a10aabfcd52f702057316018cd7847ab2bfe4aa1 (patch) | |
| tree | cc4652d2b602798934e8a48b4939cfb20eda1989 /lib/stdio.c | |
| parent | 90c29fdde317c39384011a6ba97077c138f13ad6 (diff) | |
we're bringing kjarna back and not doing the crazy stuff with trying to have task management during efi. that was a bit extra.kjarna
Diffstat (limited to 'lib/stdio.c')
| -rw-r--r-- | lib/stdio.c | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/lib/stdio.c b/lib/stdio.c deleted file mode 100644 index 70cc685..0000000 --- a/lib/stdio.c +++ /dev/null @@ -1,30 +0,0 @@ -#include <libc/stdio.h> -#include <libc/string.h> -#include <posix/unistd.h> - -struct FILE -{ - int fd; -}; - -static FILE stdin_stream = { STDIN_FILENO }; -static FILE stdout_stream = { STDOUT_FILENO }; -static FILE stderr_stream = { STDERR_FILENO }; - -FILE *stdin = &stdin_stream; -FILE *stdout = &stdout_stream; -FILE *stderr = &stderr_stream; - -int fputc(int c, FILE *f) -{ - write(f->fd, (const char *)&c, 1); - return 1; -} - -int fputs(const char *s, FILE *f) -{ - size_t slen = strlen(s); - write(f->fd, s, slen); - return (int)slen; -} - |
