X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;ds=sidebyside;f=src%2Fstdio%2Fferror.c;h=d692eed9418ea1f0cf36c948bacad20d6afc526c;hb=c8cb6bcdf009e94c12c6e256b8e24a9bc5fdaf05;hp=f535fbeda07ff8ef4f04f04ad17d956001548ce9;hpb=0b44a0315b47dd8eced9f3b7f31580cf14bbfc01;p=musl diff --git a/src/stdio/ferror.c b/src/stdio/ferror.c index f535fbed..d692eed9 100644 --- a/src/stdio/ferror.c +++ b/src/stdio/ferror.c @@ -4,7 +4,11 @@ int ferror(FILE *f) { - return !!(f->flags & F_ERR); + FLOCK(f); + int ret = !!(f->flags & F_ERR); + FUNLOCK(f); + return ret; } weak_alias(ferror, ferror_unlocked); +weak_alias(ferror, _IO_ferror_unlocked);