Date: Sat, 7 Jan 2017 09:21:21 +0000 (UTC) From: Ngie Cooper <ngie@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r311615 - stable/11/contrib/netbsd-tests/lib/libc/sys Message-ID: <201701070921.v079LLH4098147@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
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)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201701070921.v079LLH4098147>