home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / vc98 / crt / src / telli64.c < prev    next >
C/C++ Source or Header  |  1998-06-17  |  881b  |  39 lines

  1. /***
  2. *telli64.c - find file position
  3. *
  4. *       Copyright (c) 1994-1997, Microsoft Corporation. All rights reserved.
  5. *
  6. *Purpose:
  7. *       contains _telli64 - find file position
  8. *
  9. *******************************************************************************/
  10.  
  11. #include <cruntime.h>
  12. #include <io.h>
  13. #include <stdio.h>
  14.  
  15. /***
  16. *__int64 _telli64(filedes) - find file position
  17. *
  18. *Purpose:
  19. *       Gets the current position of the file pointer (no adjustment
  20. *       for buffering).
  21. *
  22. *Entry:
  23. *       int filedes - file handle of file
  24. *
  25. *Exit:
  26. *       returns file position or -1i64 (sets errno) if bad file descriptor or
  27. *       pipe
  28. *
  29. *Exceptions:
  30. *
  31. *******************************************************************************/
  32.  
  33. __int64 __cdecl _telli64 (
  34.         int filedes
  35.         )
  36. {
  37.         return( _lseeki64( filedes, 0i64, SEEK_CUR ) );
  38. }
  39.