svn commit: r311615 - stable/11/contrib/netbsd-tests/lib/libc/sys
Ngie Cooper
ngie at FreeBSD.org
Sat Jan 7 09:21:22 UTC 2017
Author: ngie
Date: Sat Jan 7 09:21:21 2017
New Revision: 311615
URL: https://svnweb.freebsd.org/changeset/base/311615
Log:
MFC r311271:
stat_symlink: don't leak fd; close the file descriptor when done
CID: 978314
Modified:
stable/11/contrib/netbsd-tests/lib/libc/sys/t_stat.c
Directory Properties:
stable/11/ (props changed)
Modified: stable/11/contrib/netbsd-tests/lib/libc/sys/t_stat.c
==============================================================================
--- stable/11/contrib/netbsd-tests/lib/libc/sys/t_stat.c Sat Jan 7 09:19:55 2017 (r311614)
+++ stable/11/contrib/netbsd-tests/lib/libc/sys/t_stat.c Sat Jan 7 09:21:21 2017 (r311615)
@@ -398,6 +398,9 @@ ATF_TC_BODY(stat_symlink, tc)
ATF_REQUIRE(unlink(path) == 0);
ATF_REQUIRE(unlink(pathlink) == 0);
+#ifdef __FreeBSD__
+ (void)close(fd);
+#endif
}
ATF_TC_CLEANUP(stat_symlink, tc)
More information about the svn-src-stable
mailing list