summaryrefslogtreecommitdiff
path: root/usr.bin/gzip
diff options
context:
space:
mode:
authorXin LI <delphij@FreeBSD.org>2017-12-12 06:56:21 +0000
committerXin LI <delphij@FreeBSD.org>2017-12-12 06:56:21 +0000
commitf5e46072651b1c9083c86b80e578038cc5aee8ee (patch)
tree62a145a84469a3945f48fda37fde8a9c8525b2be /usr.bin/gzip
parentbf1b92967f15946229be0b19584f4c4c4524c005 (diff)
downloadsrc-test-f5e46072651b1c9083c86b80e578038cc5aee8ee.tar.gz
src-test-f5e46072651b1c9083c86b80e578038cc5aee8ee.zip
Close the correct file descriptor.
MFC after: 2 weeks
Notes
Notes: svn path=/head/; revision=326791
Diffstat (limited to 'usr.bin/gzip')
-rw-r--r--usr.bin/gzip/gzip.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/gzip/gzip.c b/usr.bin/gzip/gzip.c
index 60e025894d8b9..9df52371323f2 100644
--- a/usr.bin/gzip/gzip.c
+++ b/usr.bin/gzip/gzip.c
@@ -1718,7 +1718,7 @@ file_uncompress(char *file, char *outfile, size_t outsize)
if (fd != -1)
close(fd);
if (zfd != -1 && zfd != STDOUT_FILENO)
- close(fd);
+ close(zfd);
return -1;
}