summaryrefslogtreecommitdiff
path: root/libc/stdio/fgetpos.c
diff options
context:
space:
mode:
authorPeter S. Mazinger <ps.m@gmx.net>2005-11-21 18:32:07 +0000
committerPeter S. Mazinger <ps.m@gmx.net>2005-11-21 18:32:07 +0000
commit25fbf2080e743bc6ddd3674789d8836b185cb924 (patch)
tree5ac0343276c82ae209a3373d236be052e6d98bb4 /libc/stdio/fgetpos.c
parentb27c9f65148e96c01cafe37490d054bdeded5f2a (diff)
Hide some
Diffstat (limited to 'libc/stdio/fgetpos.c')
-rw-r--r--libc/stdio/fgetpos.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/libc/stdio/fgetpos.c b/libc/stdio/fgetpos.c
index 84cf0b98c..03c18ab93 100644
--- a/libc/stdio/fgetpos.c
+++ b/libc/stdio/fgetpos.c
@@ -7,6 +7,10 @@
#include "_stdio.h"
+#ifndef __DO_LARGEFILE
+#define FTELL __ftell
+#endif
+
int fgetpos(FILE * __restrict stream, register fpos_t * __restrict pos)
{
#ifdef __STDIO_MBSTATE
@@ -16,7 +20,7 @@ int fgetpos(FILE * __restrict stream, register fpos_t * __restrict pos)
__STDIO_AUTO_THREADLOCK(stream);
- if ((pos->__pos = ftell(stream)) >= 0) {
+ if ((pos->__pos = FTELL(stream)) >= 0) {
__COPY_MBSTATE(&(pos->__mbstate), &(stream->__state));
pos->__mblen_pending = stream->__ungot_width[0];
retval = 0;
@@ -28,7 +32,7 @@ int fgetpos(FILE * __restrict stream, register fpos_t * __restrict pos)
#else
- return ((pos->__pos = ftell(stream)) >= 0) ? 0 : -1;
+ return ((pos->__pos = FTELL(stream)) >= 0) ? 0 : -1;
#endif
}