seek.c 332 B

12345678910111213
  1. /*
  2. * (c) copyright 1987 by the Vrije Universiteit, Amsterdam, The Netherlands.
  3. * See the copyright notice in the ACK home directory, in the file "Copyright".
  4. */
  5. /* $Id$ */
  6. #include "system.h"
  7. int sys_seek(File *fp, long off, int whence, long *poff)
  8. {
  9. if (! fp) return 0;
  10. return (*poff = lseek(fp->o_fd, off, whence)) >= 0;
  11. }