Rev 4482 | Rev 4509 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 4482 | Rev 4508 | ||
---|---|---|---|
Line 35... | Line 35... | ||
35 | #ifndef LIBC_STDIO_H_ |
35 | #ifndef LIBC_STDIO_H_ |
36 | #define LIBC_STDIO_H_ |
36 | #define LIBC_STDIO_H_ |
37 | 37 | ||
38 | #include <sys/types.h> |
38 | #include <sys/types.h> |
39 | #include <stdarg.h> |
39 | #include <stdarg.h> |
- | 40 | #include <libadt/list.h> |
|
40 | 41 | ||
41 | #define EOF (-1) |
42 | #define EOF (-1) |
42 | 43 | ||
43 | #define DEBUG(fmt, ...) \ |
44 | #define DEBUG(fmt, ...) \ |
44 | { \ |
45 | { \ |
Line 53... | Line 54... | ||
53 | #define SEEK_CUR 1 |
54 | #define SEEK_CUR 1 |
54 | #define SEEK_END 2 |
55 | #define SEEK_END 2 |
55 | #endif |
56 | #endif |
56 | 57 | ||
57 | typedef struct { |
58 | typedef struct { |
- | 59 | /** Linked list pointer. */ |
|
- | 60 | link_t link; |
|
- | 61 | ||
58 | /** Underlying file descriptor. */ |
62 | /** Underlying file descriptor. */ |
59 | int fd; |
63 | int fd; |
60 | 64 | ||
61 | /** Error indicator. */ |
65 | /** Error indicator. */ |
62 | int error; |
66 | int error; |
Line 69... | Line 73... | ||
69 | 73 | ||
70 | /** Phone to the file provider */ |
74 | /** Phone to the file provider */ |
71 | int phone; |
75 | int phone; |
72 | } FILE; |
76 | } FILE; |
73 | 77 | ||
74 | extern FILE stdin_null; |
- | |
75 | extern FILE stdout_klog; |
- | |
76 | - | ||
77 | extern FILE *stdin; |
78 | extern FILE *stdin; |
78 | extern FILE *stdout; |
79 | extern FILE *stdout; |
79 | extern FILE *stderr; |
80 | extern FILE *stderr; |
80 | 81 | ||
81 | /* Character and string input functions */ |
82 | /* Character and string input functions */ |