]> pd.if.org Git - pdclib/blobdiff - functions/stdio/fseek.c
restrict keyword cleanup.
[pdclib] / functions / stdio / fseek.c
index e3d3e7791836e7e92e25b293a6fe7ec853099fbe..9a945477445c4642291748ba17cd86cd97fe4855 100644 (file)
@@ -12,7 +12,7 @@
 
 #include <_PDCLIB_glue.h>
 
-int fseek( struct _PDCLIB_file_t * _PDCLIB_restrict stream, long offset, int whence )
+int fseek( struct _PDCLIB_file_t * stream, long offset, int whence )
 {
     if ( stream->status & _PDCLIB_FWRITE )
     {
@@ -26,7 +26,7 @@ int fseek( struct _PDCLIB_file_t * _PDCLIB_restrict stream, long offset, int whe
     {
         stream->status &= ~ ( _PDCLIB_FREAD | _PDCLIB_FWRITE );
     }
-    return _PDCLIB_seek( stream, offset, whence );
+    return ( _PDCLIB_seek( stream, offset, whence ) == offset ) ? 0 : EOF;
 }
 
 #endif