X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;ds=sidebyside;f=src%2Fstdio%2F__toread.c;h=f142ff09c087ef5459a29acd004fd005ddfc8a0c;hb=c99b7daafdbf1e2415bf408e67ca7813e7ddeedf;hp=8f9f27bd9554a8133c59c57edd373ac341649a3e;hpb=50a298ea3b122efbb31e7674a20e6c7dc30ca1dc;p=musl diff --git a/src/stdio/__toread.c b/src/stdio/__toread.c index 8f9f27bd..f142ff09 100644 --- a/src/stdio/__toread.c +++ b/src/stdio/__toread.c @@ -3,7 +3,7 @@ int __toread(FILE *f) { f->mode |= f->mode-1; - if (f->wpos > f->wbase) f->write(f, 0, 0); + if (f->wpos != f->wbase) f->write(f, 0, 0); f->wpos = f->wbase = f->wend = 0; if (f->flags & F_NORD) { f->flags |= F_ERR; @@ -13,7 +13,7 @@ int __toread(FILE *f) return (f->flags & F_EOF) ? EOF : 0; } -void __toread_needs_stdio_exit() +hidden void __toread_needs_stdio_exit() { __stdio_exit_needed(); }