summaryrefslogtreecommitdiff
path: root/lib/libc/stdio/fsetpos.c
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>2000-02-21 22:11:23 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>2000-02-21 22:11:23 +0000
commitc73a0ad4b650731afc9ff73ce3efa6a20bc12d0a (patch)
treecb01bc14f869b62fbde1335281f99360545f3170 /lib/libc/stdio/fsetpos.c
parentc08bffdba7eb5dccf57b3c21bb64592637f27391 (diff)
Add fseeko() and ftello() -- versions of fseek() and ftell() that use off_t.
Also make fsetpos() and fgetpos() use fseeko() and ftello() respectively since fpos_t is actually a 64bit type.
Diffstat (limited to 'lib/libc/stdio/fsetpos.c')
-rw-r--r--lib/libc/stdio/fsetpos.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libc/stdio/fsetpos.c b/lib/libc/stdio/fsetpos.c
index c6fae71d7b0..bc538ee4f7e 100644
--- a/lib/libc/stdio/fsetpos.c
+++ b/lib/libc/stdio/fsetpos.c
@@ -35,18 +35,18 @@
*/
#if defined(LIBC_SCCS) && !defined(lint)
-static char rcsid[] = "$OpenBSD: fsetpos.c,v 1.2 1996/08/19 08:32:47 tholo Exp $";
+static char rcsid[] = "$OpenBSD: fsetpos.c,v 1.3 2000/02/21 22:11:22 millert Exp $";
#endif /* LIBC_SCCS and not lint */
#include <stdio.h>
/*
- * fsetpos: like fseek.
+ * fsetpos: like fseeko.
*/
int
fsetpos(iop, pos)
FILE *iop;
const fpos_t *pos;
{
- return (fseek(iop, (long)*pos, SEEK_SET));
+ return (fseeko(iop, (off_t)*pos, SEEK_SET));
}