Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 22 Oct 2010 23:12:46 +0000 (UTC)
From:      "David E. O'Brien" <obrien@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org
Subject:   svn commit: r214230 - in stable/7: . bin/sh contrib/wpa_supplicant gnu/usr.bin/groff/tmac share/misc tools/regression/bin/sh tools/regression/bin/sh/builtins tools/regression/bin/sh/errors tools/re...
Message-ID:  <201010222312.o9MNCkWB069114@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: obrien
Date: Fri Oct 22 23:12:45 2010
New Revision: 214230
URL: http://svn.freebsd.org/changeset/base/214230

Log:
  MFC
    r213738: allow one to regression test 'sh' changes without having to
             install a potentially bad /bin/sh first.
    r213903: default to 'sh' from PATH if 'SH' env is not set.

Modified:
  stable/7/bin/sh/Makefile
  stable/7/tools/regression/bin/sh/Makefile
  stable/7/tools/regression/bin/sh/builtins/var-assign.0
  stable/7/tools/regression/bin/sh/errors/option-error.0
  stable/7/tools/regression/bin/sh/errors/redirection-error.0
  stable/7/tools/regression/bin/sh/execution/func1.0
  stable/7/tools/regression/bin/sh/regress.sh
  stable/7/tools/regression/bin/sh/regress.t
Directory Properties:
  stable/7/   (props changed)
  stable/7/COPYRIGHT   (props changed)
  stable/7/Makefile   (props changed)
  stable/7/Makefile.inc1   (props changed)
  stable/7/ObsoleteFiles.inc   (props changed)
  stable/7/UPDATING   (props changed)
  stable/7/bin/   (props changed)
  stable/7/bin/chflags/   (props changed)
  stable/7/bin/chio/   (props changed)
  stable/7/bin/cp/   (props changed)
  stable/7/bin/csh/   (props changed)
  stable/7/bin/dd/   (props changed)
  stable/7/bin/df/   (props changed)
  stable/7/bin/expr/   (props changed)
  stable/7/bin/kill/   (props changed)
  stable/7/bin/ln/   (props changed)
  stable/7/bin/ls/   (props changed)
  stable/7/bin/pax/   (props changed)
  stable/7/bin/ps/   (props changed)
  stable/7/bin/rm/   (props changed)
  stable/7/bin/sh/   (props changed)
  stable/7/bin/test/   (props changed)
  stable/7/cddl/contrib/opensolaris/   (props changed)
  stable/7/cddl/lib/libzpool/   (props changed)
  stable/7/contrib/   (props changed)
  stable/7/contrib/bind9/   (props changed)
  stable/7/contrib/binutils/   (props changed)
  stable/7/contrib/bsnmp/   (props changed)
  stable/7/contrib/cpio/   (props changed)
  stable/7/contrib/csup/   (props changed)
  stable/7/contrib/expat/   (props changed)
  stable/7/contrib/gcc/   (props changed)
  stable/7/contrib/gdb/   (props changed)
  stable/7/contrib/gdtoa/   (props changed)
  stable/7/contrib/groff/   (props changed)
  stable/7/contrib/ipfilter/   (props changed)
  stable/7/contrib/less/   (props changed)
  stable/7/contrib/libpcap/   (props changed)
  stable/7/contrib/ncurses/   (props changed)
  stable/7/contrib/netcat/   (props changed)
  stable/7/contrib/ntp/   (props changed)
  stable/7/contrib/nvi/   (props changed)
  stable/7/contrib/pf/   (props changed)
  stable/7/contrib/sendmail/   (props changed)
  stable/7/contrib/smbfs/   (props changed)
  stable/7/contrib/tcp_wrappers/   (props changed)
  stable/7/contrib/tcsh/   (props changed)
  stable/7/contrib/telnet/   (props changed)
  stable/7/contrib/top/   (props changed)
  stable/7/contrib/traceroute/   (props changed)
  stable/7/contrib/wpa_supplicant/   (props changed)
  stable/7/contrib/wpa_supplicant/wpa_supplicant.conf   (props changed)
  stable/7/crypto/openssh/   (props changed)
  stable/7/etc/   (props changed)
  stable/7/games/factor/   (props changed)
  stable/7/games/fortune/   (props changed)
  stable/7/games/grdc/   (props changed)
  stable/7/gnu/   (props changed)
  stable/7/gnu/lib/libstdc++/   (props changed)
  stable/7/gnu/usr.bin/   (props changed)
  stable/7/gnu/usr.bin/cc/   (props changed)
  stable/7/gnu/usr.bin/cpio/   (props changed)
  stable/7/gnu/usr.bin/cvs/   (props changed)
  stable/7/gnu/usr.bin/gdb/   (props changed)
  stable/7/gnu/usr.bin/gdb/kgdb/   (props changed)
  stable/7/gnu/usr.bin/grep/   (props changed)
  stable/7/gnu/usr.bin/groff/   (props changed)
  stable/7/gnu/usr.bin/groff/tmac/mdoc.local   (props changed)
  stable/7/gnu/usr.bin/man/   (props changed)
  stable/7/gnu/usr.bin/sort/   (props changed)
  stable/7/include/   (props changed)
  stable/7/kerberos5/   (props changed)
  stable/7/lib/   (props changed)
  stable/7/lib/bind/   (props changed)
  stable/7/lib/csu/   (props changed)
  stable/7/lib/libarchive/   (props changed)
  stable/7/lib/libbluetooth/   (props changed)
  stable/7/lib/libc/   (props changed)
  stable/7/lib/libc/stdtime/   (props changed)
  stable/7/lib/libc_r/   (props changed)
  stable/7/lib/libcam/   (props changed)
  stable/7/lib/libdisk/   (props changed)
  stable/7/lib/libdwarf/   (props changed)
  stable/7/lib/libelf/   (props changed)
  stable/7/lib/libexpat/   (props changed)
  stable/7/lib/libfetch/   (props changed)
  stable/7/lib/libftpio/   (props changed)
  stable/7/lib/libgeom/   (props changed)
  stable/7/lib/libgssapi/   (props changed)
  stable/7/lib/libkse/   (props changed)
  stable/7/lib/libkvm/   (props changed)
  stable/7/lib/libmagic/   (props changed)
  stable/7/lib/libmemstat/   (props changed)
  stable/7/lib/libpmc/   (props changed)
  stable/7/lib/libradius/   (props changed)
  stable/7/lib/libsm/   (props changed)
  stable/7/lib/libstand/   (props changed)
  stable/7/lib/libthr/   (props changed)
  stable/7/lib/libthread_db/   (props changed)
  stable/7/lib/libufs/   (props changed)
  stable/7/lib/libutil/   (props changed)
  stable/7/lib/msun/   (props changed)
  stable/7/libexec/   (props changed)
  stable/7/libexec/ftpd/   (props changed)
  stable/7/libexec/rpc.rquotad/   (props changed)
  stable/7/libexec/rpc.rstatd/   (props changed)
  stable/7/libexec/rtld-elf/   (props changed)
  stable/7/libexec/tftpd/   (props changed)
  stable/7/release/   (props changed)
  stable/7/release/doc/   (props changed)
  stable/7/release/doc/en_US.ISO8859-1/hardware/   (props changed)
  stable/7/release/picobsd/tinyware/login/   (props changed)
  stable/7/rescue/   (props changed)
  stable/7/sbin/   (props changed)
  stable/7/sbin/atacontrol/   (props changed)
  stable/7/sbin/bsdlabel/   (props changed)
  stable/7/sbin/clri/   (props changed)
  stable/7/sbin/ddb/   (props changed)
  stable/7/sbin/devd/   (props changed)
  stable/7/sbin/devfs/   (props changed)
  stable/7/sbin/dhclient/   (props changed)
  stable/7/sbin/dumpfs/   (props changed)
  stable/7/sbin/fdisk/   (props changed)
  stable/7/sbin/fdisk_pc98/   (props changed)
  stable/7/sbin/fsck/   (props changed)
  stable/7/sbin/fsck_ffs/   (props changed)
  stable/7/sbin/fsck_msdosfs/   (props changed)
  stable/7/sbin/geom/   (props changed)
  stable/7/sbin/geom/class/label/   (props changed)
  stable/7/sbin/geom/class/part/   (props changed)
  stable/7/sbin/geom/class/stripe/   (props changed)
  stable/7/sbin/geom/misc/   (props changed)
  stable/7/sbin/growfs/   (props changed)
  stable/7/sbin/ifconfig/   (props changed)
  stable/7/sbin/init/   (props changed)
  stable/7/sbin/ipf/   (props changed)
  stable/7/sbin/ipfw/   (props changed)
  stable/7/sbin/md5/   (props changed)
  stable/7/sbin/mdconfig/   (props changed)
  stable/7/sbin/mksnap_ffs/   (props changed)
  stable/7/sbin/mount/   (props changed)
  stable/7/sbin/mount_msdosfs/   (props changed)
  stable/7/sbin/natd/   (props changed)
  stable/7/sbin/newfs/   (props changed)
  stable/7/sbin/newfs_msdos/   (props changed)
  stable/7/sbin/ping6/   (props changed)
  stable/7/sbin/reboot/   (props changed)
  stable/7/sbin/restore/   (props changed)
  stable/7/sbin/route/   (props changed)
  stable/7/sbin/savecore/   (props changed)
  stable/7/sbin/sconfig/   (props changed)
  stable/7/sbin/shutdown/   (props changed)
  stable/7/sbin/sysctl/   (props changed)
  stable/7/sbin/tunefs/   (props changed)
  stable/7/secure/lib/libssh/   (props changed)
  stable/7/secure/libexec/sftp-server/   (props changed)
  stable/7/secure/usr.bin/bdes/   (props changed)
  stable/7/secure/usr.bin/ssh/   (props changed)
  stable/7/secure/usr.sbin/sshd/   (props changed)
  stable/7/share/   (props changed)
  stable/7/share/colldef/   (props changed)
  stable/7/share/dict/   (props changed)
  stable/7/share/doc/bind9/   (props changed)
  stable/7/share/examples/   (props changed)
  stable/7/share/man/   (props changed)
  stable/7/share/man/man1/   (props changed)
  stable/7/share/man/man3/   (props changed)
  stable/7/share/man/man4/   (props changed)
  stable/7/share/man/man5/   (props changed)
  stable/7/share/man/man7/   (props changed)
  stable/7/share/man/man8/   (props changed)
  stable/7/share/man/man9/   (props changed)
  stable/7/share/misc/   (props changed)
  stable/7/share/misc/iso639   (props changed)
  stable/7/share/misc/pci_vendors   (props changed)
  stable/7/share/mk/   (props changed)
  stable/7/share/mklocale/   (props changed)
  stable/7/share/monetdef/   (props changed)
  stable/7/share/msgdef/   (props changed)
  stable/7/share/numericdef/   (props changed)
  stable/7/share/sendmail/   (props changed)
  stable/7/share/syscons/   (props changed)
  stable/7/share/syscons/keymaps/   (props changed)
  stable/7/share/termcap/   (props changed)
  stable/7/share/timedef/   (props changed)
  stable/7/share/zoneinfo/   (props changed)
  stable/7/sys/   (props changed)
  stable/7/sys/cddl/contrib/opensolaris/   (props changed)
  stable/7/sys/contrib/dev/acpica/   (props changed)
  stable/7/sys/contrib/pf/   (props changed)
  stable/7/tools/   (props changed)
  stable/7/tools/build/   (props changed)
  stable/7/tools/build/options/   (props changed)
  stable/7/tools/debugscripts/   (props changed)
  stable/7/tools/regression/atm/   (props changed)
  stable/7/tools/regression/bin/sh/   (props changed)
  stable/7/tools/regression/file/   (props changed)
  stable/7/tools/regression/file/flock/   (props changed)
  stable/7/tools/regression/usr.bin/   (props changed)
  stable/7/tools/regression/usr.bin/jot/   (props changed)
  stable/7/tools/regression/usr.bin/tr/   (props changed)
  stable/7/tools/sched/   (props changed)
  stable/7/tools/test/   (props changed)
  stable/7/tools/tools/   (props changed)
  stable/7/tools/tools/aac/   (props changed)
  stable/7/tools/tools/crypto/   (props changed)
  stable/7/tools/tools/editing/   (props changed)
  stable/7/tools/tools/nanobsd/   (props changed)
  stable/7/tools/tools/nanobsd/FlashDevice.sub   (props changed)
  stable/7/tools/tools/nanobsd/nanobsd.sh   (props changed)
  stable/7/tools/tools/netrate/   (props changed)
  stable/7/tools/tools/umastat/   (props changed)
  stable/7/tools/tools/usb/   (props changed)
  stable/7/usr.bin/   (props changed)
  stable/7/usr.bin/basename/   (props changed)
  stable/7/usr.bin/bluetooth/rfcomm_sppd/   (props changed)
  stable/7/usr.bin/calendar/   (props changed)
  stable/7/usr.bin/catman/   (props changed)
  stable/7/usr.bin/cksum/   (props changed)
  stable/7/usr.bin/comm/   (props changed)
  stable/7/usr.bin/cpuset/   (props changed)
  stable/7/usr.bin/csup/   (props changed)
  stable/7/usr.bin/dirname/   (props changed)
  stable/7/usr.bin/du/   (props changed)
  stable/7/usr.bin/fetch/   (props changed)
  stable/7/usr.bin/file/   (props changed)
  stable/7/usr.bin/find/   (props changed)
  stable/7/usr.bin/finger/   (props changed)
  stable/7/usr.bin/fstat/   (props changed)
  stable/7/usr.bin/gcore/   (props changed)
  stable/7/usr.bin/gprof/   (props changed)
  stable/7/usr.bin/gzip/   (props changed)
  stable/7/usr.bin/hexdump/   (props changed)
  stable/7/usr.bin/id/   (props changed)
  stable/7/usr.bin/indent/   (props changed)
  stable/7/usr.bin/ipcrm/   (props changed)
  stable/7/usr.bin/ipcs/   (props changed)
  stable/7/usr.bin/jot/   (props changed)
  stable/7/usr.bin/kdump/   (props changed)
  stable/7/usr.bin/ktrace/   (props changed)
  stable/7/usr.bin/ldd/   (props changed)
  stable/7/usr.bin/less/   (props changed)
  stable/7/usr.bin/locate/   (props changed)
  stable/7/usr.bin/lockf/   (props changed)
  stable/7/usr.bin/logger/   (props changed)
  stable/7/usr.bin/make/   (props changed)
  stable/7/usr.bin/ncal/   (props changed)
  stable/7/usr.bin/netstat/   (props changed)
  stable/7/usr.bin/newgrp/   (props changed)
  stable/7/usr.bin/nsupdate/   (props changed)
  stable/7/usr.bin/pkill/   (props changed)
  stable/7/usr.bin/procstat/   (props changed)
  stable/7/usr.bin/quota/   (props changed)
  stable/7/usr.bin/rpcgen/   (props changed)
  stable/7/usr.bin/ruptime/   (props changed)
  stable/7/usr.bin/script/   (props changed)
  stable/7/usr.bin/sed/   (props changed)
  stable/7/usr.bin/shar/   (props changed)
  stable/7/usr.bin/sockstat/   (props changed)
  stable/7/usr.bin/stat/   (props changed)
  stable/7/usr.bin/su/   (props changed)
  stable/7/usr.bin/systat/   (props changed)
  stable/7/usr.bin/tail/   (props changed)
  stable/7/usr.bin/tar/   (props changed)
  stable/7/usr.bin/tftp/   (props changed)
  stable/7/usr.bin/tip/   (props changed)
  stable/7/usr.bin/top/   (props changed)
  stable/7/usr.bin/truncate/   (props changed)
  stable/7/usr.bin/truss/   (props changed)
  stable/7/usr.bin/uname/   (props changed)
  stable/7/usr.bin/unifdef/   (props changed)
  stable/7/usr.bin/units/   (props changed)
  stable/7/usr.bin/vmstat/   (props changed)
  stable/7/usr.bin/w/   (props changed)
  stable/7/usr.bin/wc/   (props changed)
  stable/7/usr.bin/whereis/   (props changed)
  stable/7/usr.bin/whois/   (props changed)
  stable/7/usr.bin/window/   (props changed)
  stable/7/usr.bin/xargs/   (props changed)
  stable/7/usr.bin/ypcat/   (props changed)
  stable/7/usr.bin/ypmatch/   (props changed)
  stable/7/usr.bin/ypwhich/   (props changed)
  stable/7/usr.sbin/   (props changed)
  stable/7/usr.sbin/Makefile   (props changed)
  stable/7/usr.sbin/acpi/   (props changed)
  stable/7/usr.sbin/adduser/   (props changed)
  stable/7/usr.sbin/arp/   (props changed)
  stable/7/usr.sbin/bluetooth/   (props changed)
  stable/7/usr.sbin/bluetooth/btpand/   (props changed)
  stable/7/usr.sbin/bluetooth/hcsecd/   (props changed)
  stable/7/usr.sbin/bluetooth/hcseriald/   (props changed)
  stable/7/usr.sbin/bluetooth/rfcomm_pppd/   (props changed)
  stable/7/usr.sbin/bluetooth/sdpd/   (props changed)
  stable/7/usr.sbin/boot0cfg/   (props changed)
  stable/7/usr.sbin/bsnmpd/modules/snmp_pf/   (props changed)
  stable/7/usr.sbin/burncd/   (props changed)
  stable/7/usr.sbin/cdcontrol/   (props changed)
  stable/7/usr.sbin/chown/   (props changed)
  stable/7/usr.sbin/chroot/   (props changed)
  stable/7/usr.sbin/config/   (props changed)
  stable/7/usr.sbin/cpucontrol/   (props changed)
  stable/7/usr.sbin/crashinfo/   (props changed)
  stable/7/usr.sbin/cron/   (props changed)
  stable/7/usr.sbin/cron/cron/   (props changed)
  stable/7/usr.sbin/crunch/   (props changed)
  stable/7/usr.sbin/cxgbtool/   (props changed)
  stable/7/usr.sbin/eeprom/   (props changed)
  stable/7/usr.sbin/extattr/   (props changed)
  stable/7/usr.sbin/faithd/   (props changed)
  stable/7/usr.sbin/fdcontrol/   (props changed)
  stable/7/usr.sbin/fdformat/   (props changed)
  stable/7/usr.sbin/fdread/   (props changed)
  stable/7/usr.sbin/fdwrite/   (props changed)
  stable/7/usr.sbin/fifolog/   (props changed)
  stable/7/usr.sbin/freebsd-update/   (props changed)
  stable/7/usr.sbin/fwcontrol/   (props changed)
  stable/7/usr.sbin/gstat/   (props changed)
  stable/7/usr.sbin/iostat/   (props changed)
  stable/7/usr.sbin/jail/   (props changed)
  stable/7/usr.sbin/jexec/   (props changed)
  stable/7/usr.sbin/jls/   (props changed)
  stable/7/usr.sbin/lpr/   (props changed)
  stable/7/usr.sbin/mailwrapper/   (props changed)
  stable/7/usr.sbin/makefs/   (props changed)
  stable/7/usr.sbin/makefs/ffs/ffs_bswap.c   (props changed)
  stable/7/usr.sbin/makefs/ffs/ffs_subr.c   (props changed)
  stable/7/usr.sbin/makefs/ffs/ufs_bswap.h   (props changed)
  stable/7/usr.sbin/makefs/getid.c   (props changed)
  stable/7/usr.sbin/mergemaster/   (props changed)
  stable/7/usr.sbin/mfiutil/   (props changed)
  stable/7/usr.sbin/mfiutil/mfiutil.8   (props changed)
  stable/7/usr.sbin/mountd/   (props changed)
  stable/7/usr.sbin/mptutil/   (props changed)
  stable/7/usr.sbin/mtree/   (props changed)
  stable/7/usr.sbin/ndiscvt/   (props changed)
  stable/7/usr.sbin/ndp/   (props changed)
  stable/7/usr.sbin/newsyslog/   (props changed)
  stable/7/usr.sbin/nscd/   (props changed)
  stable/7/usr.sbin/ntp/   (props changed)
  stable/7/usr.sbin/pciconf/   (props changed)
  stable/7/usr.sbin/pkg_install/   (props changed)
  stable/7/usr.sbin/pmccontrol/   (props changed)
  stable/7/usr.sbin/pmcstat/   (props changed)
  stable/7/usr.sbin/portsnap/   (props changed)
  stable/7/usr.sbin/powerd/   (props changed)
  stable/7/usr.sbin/ppp/   (props changed)
  stable/7/usr.sbin/pstat/   (props changed)
  stable/7/usr.sbin/pw/   (props changed)
  stable/7/usr.sbin/pwd_mkdb/   (props changed)
  stable/7/usr.sbin/rpc.lockd/   (props changed)
  stable/7/usr.sbin/rpc.statd/   (props changed)
  stable/7/usr.sbin/rpc.yppasswdd/   (props changed)
  stable/7/usr.sbin/rtsold/   (props changed)
  stable/7/usr.sbin/sade/   (props changed)
  stable/7/usr.sbin/service/   (props changed)
  stable/7/usr.sbin/setfib/   (props changed)
  stable/7/usr.sbin/sysinstall/   (props changed)
  stable/7/usr.sbin/syslogd/   (props changed)
  stable/7/usr.sbin/traceroute/   (props changed)
  stable/7/usr.sbin/traceroute6/   (props changed)
  stable/7/usr.sbin/tzsetup/   (props changed)
  stable/7/usr.sbin/ugidfw/   (props changed)
  stable/7/usr.sbin/wpa/wpa_supplicant/   (props changed)
  stable/7/usr.sbin/ypserv/   (props changed)
  stable/7/usr.sbin/zic/   (props changed)

Modified: stable/7/bin/sh/Makefile
==============================================================================
--- stable/7/bin/sh/Makefile	Fri Oct 22 22:58:00 2010	(r214229)
+++ stable/7/bin/sh/Makefile	Fri Oct 22 23:12:45 2010	(r214230)
@@ -62,4 +62,7 @@ syntax.c syntax.h: mksyntax
 token.h: mktokens
 	sh ${.CURDIR}/mktokens
 
+regress:
+	cd ${.CURDIR}/../../tools/regression/bin/sh && ${MAKE} SH=${.OBJDIR}/sh
+
 .include <bsd.prog.mk>

Modified: stable/7/tools/regression/bin/sh/Makefile
==============================================================================
--- stable/7/tools/regression/bin/sh/Makefile	Fri Oct 22 22:58:00 2010	(r214229)
+++ stable/7/tools/regression/bin/sh/Makefile	Fri Oct 22 23:12:45 2010	(r214230)
@@ -1,4 +1,7 @@
 # $FreeBSD$
 
+# Allow one to specify the 'sh' to regress.
+SH?=	/bin/sh
+
 all:
-	sh regress.sh
+	env SH=${SH} ${SH} regress.sh

Modified: stable/7/tools/regression/bin/sh/builtins/var-assign.0
==============================================================================
--- stable/7/tools/regression/bin/sh/builtins/var-assign.0	Fri Oct 22 22:58:00 2010	(r214229)
+++ stable/7/tools/regression/bin/sh/builtins/var-assign.0	Fri Oct 22 23:12:45 2010	(r214230)
@@ -44,12 +44,12 @@ set -e
 set -- ${SPECIAL}
 for cmd in "$@"
 do
-	sh -c "VAR=1; VAR=0 ${cmd}; exit \${VAR}" >/dev/null 2>&1
+	${SH} -c "VAR=1; VAR=0 ${cmd}; exit \${VAR}" >/dev/null 2>&1
 done
 
 # For other built-ins and utilites they do not.
 set -- ${UTILS}
 for cmd in "$@"
 do
-	sh -c "VAR=0; VAR=1 ${cmd}; exit \${VAR}" >/dev/null 2>&1
+	${SH} -c "VAR=0; VAR=1 ${cmd}; exit \${VAR}" >/dev/null 2>&1
 done

Modified: stable/7/tools/regression/bin/sh/errors/option-error.0
==============================================================================
--- stable/7/tools/regression/bin/sh/errors/option-error.0	Fri Oct 22 22:58:00 2010	(r214229)
+++ stable/7/tools/regression/bin/sh/errors/option-error.0	Fri Oct 22 23:12:45 2010	(r214230)
@@ -35,12 +35,12 @@ UTILS="alias -y,\
 set -- ${SPECIAL}
 for cmd in "$@"
 do
-	sh -c "${cmd}; exit 0" 2>/dev/null && exit 1
+	${SH} -c "${cmd}; exit 0" 2>/dev/null && exit 1
 done
 
 # Other utilities must not abort.
 set -- ${UTILS}
 for cmd in "$@"
 do
-	sh -c "${cmd}; exit 0" 2>/dev/null || exit 1
+	${SH} -c "${cmd}; exit 0" 2>/dev/null || exit 1
 done

Modified: stable/7/tools/regression/bin/sh/errors/redirection-error.0
==============================================================================
--- stable/7/tools/regression/bin/sh/errors/redirection-error.0	Fri Oct 22 22:58:00 2010	(r214229)
+++ stable/7/tools/regression/bin/sh/errors/redirection-error.0	Fri Oct 22 23:12:45 2010	(r214230)
@@ -42,12 +42,12 @@ UTILS="alias,\
 set -- ${SPECIAL}
 for cmd in "$@"
 do
-	sh -c "${cmd} > /; exit 0" 2>/dev/null && exit 1
+	${SH} -c "${cmd} > /; exit 0" 2>/dev/null && exit 1
 done
 
 # Other utilities must not abort.
 set -- ${UTILS}
 for cmd in "$@"
 do
-	sh -c "${cmd} > /; exit 0" 2>/dev/null || exit 1
+	${SH} -c "${cmd} > /; exit 0" 2>/dev/null || exit 1
 done

Modified: stable/7/tools/regression/bin/sh/execution/func1.0
==============================================================================
--- stable/7/tools/regression/bin/sh/execution/func1.0	Fri Oct 22 22:58:00 2010	(r214229)
+++ stable/7/tools/regression/bin/sh/execution/func1.0	Fri Oct 22 23:12:45 2010	(r214230)
@@ -1,4 +1,4 @@
 # $FreeBSD$
 
-MALLOC_OPTIONS=J sh -c 'g() { g() { :; }; :; }; g' &&
-MALLOC_OPTIONS=J sh -c 'g() { unset -f g; :; }; g'
+MALLOC_OPTIONS=J ${SH} -c 'g() { g() { :; }; :; }; g' &&
+MALLOC_OPTIONS=J ${SH} -c 'g() { unset -f g; :; }; g'

Modified: stable/7/tools/regression/bin/sh/regress.sh
==============================================================================
--- stable/7/tools/regression/bin/sh/regress.sh	Fri Oct 22 22:58:00 2010	(r214229)
+++ stable/7/tools/regression/bin/sh/regress.sh	Fri Oct 22 23:12:45 2010	(r214230)
@@ -1,12 +1,18 @@
 # $FreeBSD$
 
+if [ -z "${SH}" ]; then
+	echo '${SH} is not set, please correct and re-run.'
+	exit 1
+fi
+export SH=${SH}
+
 COUNTER=1
 
 do_test() {
 	local c
 	c=${COUNTER}
 	COUNTER=$((COUNTER+1))
-	sh $1 > tmp.stdout 2> tmp.stderr
+	${SH} $1 > tmp.stdout 2> tmp.stderr
 	if [ $? -ne $2 ]; then
 		echo "not ok ${c} - ${1} # wrong exit status"
 		rm tmp.stdout tmp.stderr

Modified: stable/7/tools/regression/bin/sh/regress.t
==============================================================================
--- stable/7/tools/regression/bin/sh/regress.t	Fri Oct 22 22:58:00 2010	(r214229)
+++ stable/7/tools/regression/bin/sh/regress.t	Fri Oct 22 23:12:45 2010	(r214230)
@@ -1,6 +1,8 @@
 #!/bin/sh
 # $FreeBSD$
 
+export SH="${SH:-sh}"
+
 cd `dirname $0`
 
-sh regress.sh
+${SH} regress.sh



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201010222312.o9MNCkWB069114>