diff options
| author | Kacper <kacper@mail.openlinux.dev> | 2025-12-09 21:17:12 +0100 |
|---|---|---|
| committer | Kacper <kacper@mail.openlinux.dev> | 2025-12-09 21:17:12 +0100 |
| commit | b5cd18739a64c8d923a55b61c89ae3900faafd84 (patch) | |
| tree | d192f7b25257ae9a8a4760c68f5314dcbc0d9b91 /lib/libc/include/__stdio.h | |
| parent | 119aed5bc787ccbf23d2f151759ec1f3a80977e1 (diff) | |
Fix include paths and formatting inconsistencies
Diffstat (limited to 'lib/libc/include/__stdio.h')
| -rw-r--r-- | lib/libc/include/__stdio.h | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/lib/libc/include/__stdio.h b/lib/libc/include/__stdio.h new file mode 100644 index 00000000..ebda4b22 --- /dev/null +++ b/lib/libc/include/__stdio.h @@ -0,0 +1,36 @@ +#ifndef __LIBC_IO +#define __LIBC_IO + +#include <stddef.h> +#include <stdlib.h> +#include <string.h> +#include <stdint.h> +#include <sys/types.h> +#include <stdatomic.h> + +typedef __SIZE_TYPE__ size_t; + +#define _IO_ERR 0x4 +#define _IO_EOF 0x8 +#define _IO_WIDE 0x10 + +struct __FILE { + int fd; + uint32_t flags; + int type; + pid_t pid; + atomic_flag lock; + char *buf; + int eof; + size_t buf_size; + size_t buf_pos; + size_t buf_len; + unsigned char unget_buf[16]; + size_t unget_cnt; + off_t offset; + struct __FILE *next; +}; + +void __libc_fadd(struct __FILE *f); + +#endif |
