From 10e5ffc84769c4982424538b2c58daa8810daaf1 Mon Sep 17 00:00:00 2001 From: Keith Bostic Date: Sun, 21 Jun 1992 22:52:07 -0800 Subject: [PATCH] the seek function takes a fpos_t (off_t), not a long SCCS-vsn: lib/libc/stdio/fseek.c 5.8 --- usr/src/lib/libc/stdio/fseek.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/usr/src/lib/libc/stdio/fseek.c b/usr/src/lib/libc/stdio/fseek.c index 66d444e7d8..7070c756b6 100644 --- a/usr/src/lib/libc/stdio/fseek.c +++ b/usr/src/lib/libc/stdio/fseek.c @@ -9,7 +9,7 @@ */ #if defined(LIBC_SCCS) && !defined(lint) -static char sccsid[] = "@(#)fseek.c 5.7 (Berkeley) %G%"; +static char sccsid[] = "@(#)fseek.c 5.8 (Berkeley) %G%"; #endif /* LIBC_SCCS and not lint */ #include @@ -134,7 +134,7 @@ fseek(fp, offset, whence) if (fp->_flags & __SOFF) curoff = fp->_offset; else { - curoff = (*seekfn)(fp->_cookie, 0L, SEEK_CUR); + curoff = (*seekfn)(fp->_cookie, (fpos_t)0, SEEK_CUR); if (curoff == POS_ERR) goto dumb; } @@ -207,7 +207,7 @@ fseek(fp, offset, whence) */ dumb: if (__sflush(fp) || - (*seekfn)(fp->_cookie, offset, whence) == POS_ERR) { + (*seekfn)(fp->_cookie, (fpos_t)offset, whence) == POS_ERR) { return (EOF); } /* success: clear EOF indicator and discard ungetc() data */ -- 2.20.1