/uspace/trunk/libc/include/stdio.h |
---|
34,6 → 34,8 |
#define EOF (-1) |
#include <io/stream.h> |
extern int getchar(void); |
extern int puts(const char * str); |
/uspace/trunk/libc/generic/io/stream.c |
---|
117,6 → 117,12 |
return stream; |
} |
static ssize_t write_null(void *param, const void *buf, size_t count) |
{ |
return count; |
} |
fd_t open(const char *fname, int flags) |
{ |
int c = 0; |
142,6 → 148,10 |
streams[c].w = write_stderr; |
return c; |
} |
if (!strcmp(fname, "null")) { |
streams[c].w = write_null; |
return c; |
} |
} |