From 68e65d4802d9c3b3017ba7b453bb6b6703befd58 Mon Sep 17 00:00:00 2001 From: wolfwood Date: Thu, 8 Apr 2010 11:31:15 -0400 Subject: [PATCH] fixed stat errors, but not fstat errors :( --- newlib-files/syscalls.c | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/newlib-files/syscalls.c b/newlib-files/syscalls.c index f948cc8..a1ca378 100644 --- a/newlib-files/syscalls.c +++ b/newlib-files/syscalls.c @@ -1,6 +1,12 @@ -#include #include -#include <_ansi.h> +#include +#include +#include +#include +#include +#include + +//#include <_ansi.h> #include // --- Process Control --- @@ -88,7 +94,7 @@ lseek(int file, int ptr, int dir) { } int -open(const char *name, int flags, int mode) { +open(const char *name, int flags, ...) { return -1; } @@ -100,7 +106,7 @@ read(int file, char *ptr, int len) { } int -_stat(int file, struct stat *st) { +stat(const char* file, struct stat *st) { st->st_mode = S_IFCHR; return 0; } @@ -182,6 +188,8 @@ sbrk(int nbytes){ // --- Other --- -int times(struct tms *buf) { +//int times(struct tms *buf) { +//int gettimeofday(struct timeval *p, struct timezone *z){ +int gettimeofday(struct timeval *p, void *z){ return -1; }