projects
/
musl
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fix dup3 ignoring all flags but O_CLOEXEC on archs with SYS_dup2 syscall
[musl]
/
src
/
stdio
/
__toread.c
diff --git
a/src/stdio/__toread.c
b/src/stdio/__toread.c
index
8f9f27b
..
f142ff0
100644
(file)
--- a/
src/stdio/__toread.c
+++ b/
src/stdio/__toread.c
@@
-3,7
+3,7
@@
int __toread(FILE *f)
{
f->mode |= f->mode-1;
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;
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;
}
return (f->flags & F_EOF) ? EOF : 0;
}
-void __toread_needs_stdio_exit()
+
hidden
void __toread_needs_stdio_exit()
{
__stdio_exit_needed();
}
{
__stdio_exit_needed();
}