X-Git-Url: https://pd.if.org/git/?p=pdclib;a=blobdiff_plain;f=functions%2F_PDCLIB%2Fprepread.c;h=6ce38d90d2779659b62b1700fe30a7dae4436cc9;hp=d2288c7455d188e552c87c94410d47ca3059dd12;hb=7015f5842d05bd5da32523048e4260e60e9e310c;hpb=2546ca02850b8d684a694dc7373887f7aec994dc diff --git a/functions/_PDCLIB/prepread.c b/functions/_PDCLIB/prepread.c index d2288c7..6ce38d9 100644 --- a/functions/_PDCLIB/prepread.c +++ b/functions/_PDCLIB/prepread.c @@ -7,6 +7,7 @@ */ #include +#include #include <_PDCLIB_glue.h> @@ -20,7 +21,7 @@ int _PDCLIB_prepread( struct _PDCLIB_file_t * stream ) See comments on implementation-defined errno values in <_PDCLIB_config.h>. */ - _PDCLIB_errno = _PDCLIB_ERROR; + errno = EINVAL; stream->status |= _PDCLIB_ERRORFLAG; return EOF; }