about summary refs log tree commit diff
path: root/src/stdio/fclose.c
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2012-11-01 23:46:39 -0400
committerRich Felker <dalias@aerifal.cx>2012-11-01 23:46:39 -0400
commita617a8e2adaaac41dd1b662b6646e8392465801c (patch)
treef5adaf552d944be658e4f967c3f55cc2987fe12f /src/stdio/fclose.c
parent3a5aa8e49ce9a98725ceb311bb64f6168fc72d3e (diff)
downloadmusl-a617a8e2adaaac41dd1b662b6646e8392465801c.tar.gz
musl-a617a8e2adaaac41dd1b662b6646e8392465801c.tar.xz
musl-a617a8e2adaaac41dd1b662b6646e8392465801c.zip
fix more unused variable warnings
some of these were coming from stdio functions locking files without
unlocking them. I believe it's useful for this to throw a warning, so
I added a new macro that's self-documenting that the file will never
be unlocked to avoid the warning in the few places where it's wrong.
Diffstat (limited to 'src/stdio/fclose.c')
-rw-r--r--src/stdio/fclose.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/stdio/fclose.c b/src/stdio/fclose.c
index 92bf7ff8..38e8a1e3 100644
--- a/src/stdio/fclose.c
+++ b/src/stdio/fclose.c
@@ -5,8 +5,7 @@ int fclose(FILE *f)
 	int r;
 	int perm;
 	
-	/* This lock is not paired with any unlock. */
-	FLOCK(f);
+	FFINALLOCK(f);
 
 	if (!(perm = f->flags & F_PERM)) {
 		OFLLOCK();