diff options
author | Nicolas "Pixel" Noble <pixel@nobis-crew.org> | 2011-02-05 04:35:27 +0100 |
---|---|---|
committer | Nicolas "Pixel" Noble <pixel@nobis-crew.org> | 2011-02-05 04:35:27 +0100 |
commit | 61ba39a23786a7ae9694705af1d146c00a319144 (patch) | |
tree | f9ad51bee751f7e878ac3e7ad4d45f993605c37d /os/src/lseek.c | |
parent | e2d292afdb43cd7d9391128563384e1edd53c52e (diff) |
Getting rid of newlib, starting to implement a libc. Highly experimental, highly untested.
Diffstat (limited to 'os/src/lseek.c')
-rw-r--r-- | os/src/lseek.c | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/os/src/lseek.c b/os/src/lseek.c deleted file mode 100644 index 1e904a5..0000000 --- a/os/src/lseek.c +++ /dev/null @@ -1,27 +0,0 @@ -#include <reent.h> -#include <osdebug.h> -#include <errno.h> -#include "fio.h" -#include "osdebug.h" - -_off_t _lseek_r(struct _reent * reent, int fd, _off_t seek, int wheel) { - off_t r; -// DBGOUT("_lseek_r(%p, %i, %i, %i)\r\n", reent, fd, seek, wheel); - - if ((wheel != SEEK_SET) && (wheel != SEEK_CUR) && (wheel != SEEK_END)) { - reent->_errno = EINVAL; - return -1; - } - - if (!fio_is_open(fd)) { - reent->_errno = EBADF; - return -1; - } - - r = fio_seek(fd, seek, wheel); - - if (r < 0) - reent->_errno = EINVAL; - - return r; -} |