X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=src%2Fstdio%2Ffflush.c;h=af7095033bca73c25a5488ebc2769207e5483666;hb=b5a527f9ff47b0f4b32c606e385a0c27d861a475;hp=715c1d10dbed3a310123ea7ea60efb2a9eda64c3;hpb=2499cd9d9be0ba74e16a6c3dd304e6d69070be35;p=musl diff --git a/src/stdio/fflush.c b/src/stdio/fflush.c index 715c1d10..af709503 100644 --- a/src/stdio/fflush.c +++ b/src/stdio/fflush.c @@ -25,7 +25,6 @@ weak_alias(dummy, __stdout_used); int fflush(FILE *f) { int r; - FILE *next; if (f) { FLOCK(f); @@ -37,12 +36,9 @@ int fflush(FILE *f) r = __stdout_used ? fflush(__stdout_used) : 0; OFLLOCK(); - for (f=libc.ofl_head; f; f=next) { + for (f=libc.ofl_head; f; f=f->next) { FLOCK(f); - //OFLUNLOCK(); if (f->wpos > f->wbase) r |= __fflush_unlocked(f); - //OFLLOCK(); - next = f->next; FUNLOCK(f); } OFLUNLOCK();