Back to index

glibc  2.9
ftello64.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <libioP.h>
#include <errno.h>

Go to the source code of this file.


off64_t ftello64 (_IO_FILE *fp)

Function Documentation

off64_t ftello64 ( _IO_FILE fp)

Definition at line 36 of file ftello64.c.

#ifdef _G_LSEEK64
  _IO_off64_t pos;
  CHECK_FILE (fp, -1L);
  _IO_acquire_lock (fp);
  pos = _IO_seekoff_unlocked (fp, 0, _IO_seek_cur, 0);
  if (_IO_in_backup (fp) && pos != _IO_pos_BAD)
      if (fp->_mode <= 0)
       pos -= fp->_IO_save_end - fp->_IO_save_base;
  _IO_release_lock (fp);
  if (pos == _IO_pos_BAD)
#ifdef EIO
      if (errno == 0)
       __set_errno (EIO);
      return -1L;
  return pos;
  __set_errno (ENOSYS);
  return -1;

Here is the call graph for this function:

Here is the caller graph for this function: