C Language and Libraries Help (clang.hlp) (Table of Contents; Topic list)
_lseek
 Summary Example                         Up Contents Index Back
─────Run-Time Library───────────────────────────────────────────────────────
 
     The _lseek function moves the file pointer associated with
     <handle> to a new location that is <offset> bytes from <origin>.
     The next operation on the file occurs at the new location. The
     <origin> argument must be one of the following constants (defined
     in STDIO.H):
 
     SEEK_SET     SEEK_CUR     SEEK_END
 
     The _lseek function can be used to reposition the pointer anywhere
     in a file. The pointer can also be positioned beyond the end of
     the file. An attempt to position the pointer before the beginning
     of the file causes an error only if you explicitly link with
     LSEEKCHK.OBJ.
 
     Return Value
 
     The _lseek function returns the offset, in bytes, of the new
     position from the beginning of the file. A return value of -1L
     indicates an error, and errno is set to either EBADF or EINVAL.
 
     On devices incapable of seeking (such as terminals and printers),
     the return value is undefined.
                                    -♦-