projects
/
musl
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
remove explicit locking to prevent __synccall setuid during posix_spawn
[musl]
/
src
/
stdio
/
fwide.c
diff --git
a/src/stdio/fwide.c
b/src/stdio/fwide.c
index
f4da47f
..
4848068
100644
(file)
--- a/
src/stdio/fwide.c
+++ b/
src/stdio/fwide.c
@@
-5,6
+5,8
@@
int fwide(FILE *f, int mode)
{
- if (!f->mode) f->mode = NORMALIZE(mode);
- return f->mode;
+ FLOCK(f);
+ if (!f->mode) mode = f->mode = NORMALIZE(mode);
+ FUNLOCK(f);
+ return mode;
}