From owner-svn-src-head@freebsd.org Sun Sep 18 05:10:16 2016 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 702CABDFDF2; Sun, 18 Sep 2016 05:10:16 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3DB2C90E; Sun, 18 Sep 2016 05:10:16 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u8I5AFHA040140; Sun, 18 Sep 2016 05:10:15 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u8I5AF5c040139; Sun, 18 Sep 2016 05:10:15 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201609180510.u8I5AF5c040139@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 18 Sep 2016 05:10:15 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r305918 - head/tests/sys/mac/bsdextended X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 18 Sep 2016 05:10:16 -0000 Author: ngie Date: Sun Sep 18 05:10:15 2016 New Revision: 305918 URL: https://svnweb.freebsd.org/changeset/base/305918 Log: 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 MFC after: 1 week X-MFC with: r305916 Sponsored by: Dell EMC Isilon Modified: head/tests/sys/mac/bsdextended/matches_test.sh Modified: head/tests/sys/mac/bsdextended/matches_test.sh ============================================================================== --- head/tests/sys/mac/bsdextended/matches_test.sh Sun Sep 18 05:07:18 2016 (r305917) +++ head/tests/sys/mac/bsdextended/matches_test.sh Sun Sep 18 05:10:15 2016 (r305918) @@ -36,9 +36,11 @@ if ! sysctl -N security.mac.bsdextended echo "1..0 # SKIP mac_bsdextended(4) support isn't available" exit 0 fi -if ! chmod -Rf 0755 $TMPDIR; then - echo "1..0 # SKIP failed to chmod $TMPDIR" - exit 0 +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"