make stdio open, read, and write operations cancellation points
[oweals/musl.git] / src / stdio / funlockfile.c
index d69f68ee8c86e32b7b27ced9088b2c75c79442b5..f8a2a071e64596b00e52940d47d94ca7ec2bee80 100644 (file)
@@ -3,5 +3,5 @@
 
 void funlockfile(FILE *f)
 {
-       FUNLOCK(f);
+       if (!--f->lockcount) __unlockfile(f);
 }