From b7c3476f891a27bac574aa0fdda95ac820a35e63 Mon Sep 17 00:00:00 2001 From: CTurt Date: Wed, 26 Aug 2015 15:44:02 +0100 Subject: [PATCH] Fix stat --- include/file.h | 2 +- source/file.c | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/include/file.h b/include/file.h index df511b6..6af1728 100644 --- a/include/file.h +++ b/include/file.h @@ -108,10 +108,10 @@ ssize_t write(int fd, const void *buf, size_t count); int open(const char *path, int flags, int mode); int close(int fd); int unlink(const char *pathname); -int stat(const char *path, struct stat *sb); int rename(const char *oldpath, const char *newpath); int mkdir(const char *pathname, mode_t mode); int rmdir(const char *path); +int stat(const char *path, struct stat *sb); int fstat(int fd, struct stat *sb); int getdents(int fd, char *buf, size_t count); diff --git a/source/file.c b/source/file.c index d3e3204..e5d0013 100644 --- a/source/file.c +++ b/source/file.c @@ -27,11 +27,6 @@ int unlink(const char *pathname) return syscall(10, pathname); } -int stat(const char *path, struct stat *sb) -{ - return syscall(38, path, sb); -} - int rename(const char *oldpath, const char *newpath) { return syscall(128, oldpath, newpath); @@ -47,6 +42,11 @@ int rmdir(const char *path) return syscall(137, path); } +int stat(const char *path, struct stat *sb) +{ + return syscall(188, path, sb); +} + int fstat(int fd, struct stat *sb) { return syscall(189, fd, sb); -- 2.11.4.GIT