summaryrefslogtreecommitdiff
path: root/src/user/lib/stdio/misc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/user/lib/stdio/misc.c')
-rw-r--r--src/user/lib/stdio/misc.c52
1 files changed, 0 insertions, 52 deletions
diff --git a/src/user/lib/stdio/misc.c b/src/user/lib/stdio/misc.c
deleted file mode 100644
index 45144f3..0000000
--- a/src/user/lib/stdio/misc.c
+++ /dev/null
@@ -1,52 +0,0 @@
-#include <errno.h>
-#include <stdio.h>
-#include <string.h>
-#include <unistd.h>
-
-void perror(const char *s) {
- if (s) fprintf(stderr, "%s: ", s);
- fprintf(stderr, "%s\n", strerror(errno));
-}
-
-int puts(const char *s) {
- return printf("%s\n", s);
-}
-
-int getchar(void) {
- return fgetc(stdin);
-}
-
-int putchar(int c) {
- return fputc(c, stdout);
-}
-
-off_t lseek(int fd, off_t off, int whence) {
- (void)fd; (void)off; (void)whence;
- errno = ENOSYS;
- return -1;
-}
-
-int remove(const char *path) {
- return unlink(path);
-}
-
-// TODO! VFSOP_MOVE
-int rename(const char *old, const char *new) {
- (void)old; (void)new;
- errno = ENOSYS;
- return -1;
-}
-
-// TODO tmpnam
-char *tmpnam(char *s) {
- static char buf[L_tmpnam];
- if (!s) s = buf;
- strcpy(s, "/tmp/tmpnam");
- return s;
-}
-
-// TODO sscanf
-int sscanf(const char *restrict s, const char *restrict format, ...) {
- (void)s; (void)format;
- return 0;
-}