Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'newlib/libc/stdio/clearerr.c')
-rw-r--r--newlib/libc/stdio/clearerr.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/newlib/libc/stdio/clearerr.c b/newlib/libc/stdio/clearerr.c
index e242ff5e1..0923ff84d 100644
--- a/newlib/libc/stdio/clearerr.c
+++ b/newlib/libc/stdio/clearerr.c
@@ -54,12 +54,17 @@ No supporting OS subroutines are required.
#include <_ansi.h>
#include <stdio.h>
+#include "local.h"
+
+/* A subroutine version of the macro clearerr. */
+
#undef clearerr
_VOID
_DEFUN(clearerr, (fp),
FILE * fp)
{
+ CHECK_INIT(_REENT);
_flockfile (fp);
__sclearerr (fp);
_funlockfile (fp);