X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=src%2Fstdio%2Ffgetc.c;h=2578afccd28ac8f75e8bb470e99ca74015cb75f2;hb=107d68ad1737929a3e815bd28514cb56e4bedd57;hp=65a10fa61777b164daab818595c53cf496e7194c;hpb=6a4b9472fb0a85e55030b37ec3017ba0319e03f9;p=musl diff --git a/src/stdio/fgetc.c b/src/stdio/fgetc.c index 65a10fa6..2578afcc 100644 --- a/src/stdio/fgetc.c +++ b/src/stdio/fgetc.c @@ -1,14 +1,7 @@ -#include "stdio_impl.h" +#include +#include "getc.h" int fgetc(FILE *f) { - int c; - if (f->lock < 0 || !__lockfile(f)) - return getc_unlocked(f); - c = getc_unlocked(f); - __unlockfile(f); - return c; + return do_getc(f); } - -weak_alias(fgetc, getc); -weak_alias(fgetc, _IO_getc);