From 2a940c1a22765411b70679bf886714930aeaf79f Mon Sep 17 00:00:00 2001 From: Corinna Vinschen Date: Fri, 14 Mar 2003 18:39:05 +0000 Subject: * libc/include/stdio.h: Declare fgetpos, fsetpos, fseeko and ftello with internal (_fpos_t and _off_t) datatypes when compiling newlib. * libc/include/sys/unistd.h: Declare _lseek using _off_t. * libc/reent/lseekr.c (_lseek_r): Use _off_t instead of off_t. * libc/stdio/fseeko.c (fseeko): Ditto. * libc/stdio/ftello.c (ftello): Ditto. * libc/stdio/stdio.c (__swrite): Ditto. (__sseek): Ditto. * libc/stdio/fgetpos.c (fgetpos): Use _fpos_t instead of fpos_t. * libc/stdio/fseek.c (fseek): Ditto. * libc/stdio/fsetpos.c (fsetpos): Ditto. * libc/stdio/ftell.c (ftell): Ditto. * libc/stdio/local.h: Declare __sseek using _off_t. --- newlib/libc/stdio/fseek.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'newlib/libc/stdio/fseek.c') diff --git a/newlib/libc/stdio/fseek.c b/newlib/libc/stdio/fseek.c index 8912dd60c..069457854 100644 --- a/newlib/libc/stdio/fseek.c +++ b/newlib/libc/stdio/fseek.c @@ -86,7 +86,7 @@ Supporting OS subroutines required: <>, <>, <>, #include #include "local.h" -#define POS_ERR (-(fpos_t)1) +#define POS_ERR (-(_fpos_t)1) /* * Seek the given file to the given offset. @@ -100,8 +100,8 @@ fseek (fp, offset, whence) int whence; { struct _reent *ptr; - fpos_t _EXFUN ((*seekfn), (void *, fpos_t, int)); - fpos_t target, curoff; + _fpos_t _EXFUN ((*seekfn), (void *, _fpos_t, int)); + _fpos_t target, curoff; size_t n; struct stat st; int havepos; @@ -149,7 +149,7 @@ fseek (fp, offset, whence) curoff = fp->_offset; else { - curoff = (*seekfn) (fp->_cookie, (fpos_t) 0, SEEK_CUR); + curoff = (*seekfn) (fp->_cookie, (_fpos_t) 0, SEEK_CUR); if (curoff == -1L) { _funlockfile(fp); -- cgit v1.2.3