Date: Fri, 21 Oct 2016 08:22:39 +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: r307715 - stable/11/tests/sys/mac/bsdextended Message-ID: <201610210822.u9L8MdCw055941@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: ngie Date: Fri Oct 21 08:22:39 2016 New Revision: 307715 URL: https://svnweb.freebsd.org/changeset/base/307715 Log: MFC r305916,r305918: r305916: Make sure $TMPDIR is created with 0755 permissions This is required to ensure that the temporary script can be executed, as the default mode is apparently too restrictive r305918: Only chmod $TMPDIR if it's not /tmp This is a safety belt to ensure that the /tmp sticky bit stuff doesn't get whacked by accident if someone runs the script outright Modified: stable/11/tests/sys/mac/bsdextended/matches_test.sh Directory Properties: stable/11/ (props changed) Modified: stable/11/tests/sys/mac/bsdextended/matches_test.sh ============================================================================== --- stable/11/tests/sys/mac/bsdextended/matches_test.sh Fri Oct 21 08:21:23 2016 (r307714) +++ stable/11/tests/sys/mac/bsdextended/matches_test.sh Fri Oct 21 08:22:39 2016 (r307715) @@ -36,6 +36,12 @@ if ! sysctl -N security.mac.bsdextended echo "1..0 # SKIP mac_bsdextended(4) support isn't available" exit 0 fi +if [ "$TMPDIR" != "/tmp" ]; then + if ! chmod -Rf 0755 $TMPDIR; then + echo "1..0 # SKIP failed to chmod $TMPDIR" + exit 0 + fi +fi if ! playground=$(mktemp -d $TMPDIR/tmp.XXXXXXX); then echo "1..0 # SKIP failed to create temporary directory" exit 0
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201610210822.u9L8MdCw055941>