#include "__stdio.h" // for __FILE, _IO_ERR #include "stddef.h" // for NULL #include // for LIBC_UNLOCK, LIBC_LOCK #include // for errno, EBADF, EIO #include int fflush(struct __FILE *stream) { int r; flockfile(stream); r = fflush_unlocked(stream); funlockfile(stream); return r; }