delorie.com/djgpp/doc/libc/libc_548.html | search |
[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
#include <unistd.h> off_t lseek(int fd, off_t offset, int whence); |
This function moves the file pointer for handle fd according to whence:
SEEK_SET
The file pointer is moved to the offset specified.
SEEK_CUR
The file pointer is moved offset bytes relative to its current position.
SEEK_END
The file pointer is moved to a position offset bytes from the end of the file. The value of offset is usually nonpositive in this case.
The new offset is returned, or -1 and errno
set on failure.
ANSI/ISO C | No |
POSIX | 1003.2-1992; 1003.1-2001 |
lseek(fd, 12, SEEK_CUR); /* skip 12 bytes */ |
webmaster | delorie software privacy |
Copyright © 2004 | Updated Apr 2004 |