--- /dev/null
+/* int64_t _PDCLIB_seek( FILE *, int64_t, int )\r
+\r
+ This file is part of the Public Domain C Library (PDCLib).\r
+ Permission is granted to use, modify, and / or redistribute at will.\r
+*/\r
+\r
+#include <stdio.h>\r
+#include <stdint.h>\r
+#include <errno.h>\r
+#ifndef REGTEST\r
+\r
+int_fast64_t _PDCLIB_seek( struct _PDCLIB_file_t * stream, _PDCLIB_int64_t offset, \r
+ int whence )\r
+{\r
+ int_fast64_t newPos;\r
+ if(!stream->ops->seek(stream->handle, offset, whence, &newPos)) {\r
+ return EOF;\r
+ }\r
+\r
+ stream->ungetidx = 0;\r
+ stream->bufidx = 0;\r
+ stream->bufend = 0;\r
+ stream->pos.offset = newPos;\r
+ return newPos;\r
+}\r
+\r
+#endif\r
+\r
+#ifdef TEST\r
+#include <_PDCLIB_test.h>\r
+\r
+int main( void )\r
+{\r
+ /* Testing covered by ftell.c */\r
+ return TEST_RESULTS;\r
+}\r
+\r
+#endif\r
+\r