X-Git-Url: https://pd.if.org/git/?p=pdclib;a=blobdiff_plain;f=functions%2Fstdio%2Ffclose.c;h=113845b83211294ff9cfa23d332bdf7bb4ef038a;hp=81b57c49a4b0c281c195596f9cda94fe7f42e326;hb=7015f5842d05bd5da32523048e4260e60e9e310c;hpb=2546ca02850b8d684a694dc7373887f7aec994dc diff --git a/functions/stdio/fclose.c b/functions/stdio/fclose.c index 81b57c4..113845b 100644 --- a/functions/stdio/fclose.c +++ b/functions/stdio/fclose.c @@ -8,6 +8,7 @@ #include #include +#include #ifndef REGTEST #include <_PDCLIB_glue.h> @@ -58,10 +59,8 @@ int fclose( struct _PDCLIB_file_t * stream ) previous = current; current = current->next; } - /* See the comments on implementation-defined errno values in - <_PDCLIB_config.h>. - */ - _PDCLIB_errno = _PDCLIB_ERROR; + + errno = EINVAL; return -1; }