mirror of
https://github.com/opnsense/src.git
synced 2026-02-14 08:13:38 -05:00
POSIX requires this and it is simpler than the previous code that remembered command locations when appending directories to PATH. In particular, PATH=$PATH is no longer a no-op but discards all cached command locations.
12 lines
190 B
Text
12 lines
190 B
Text
# $FreeBSD$
|
|
|
|
T=`mktemp -d "${TMPDIR:-/tmp}/sh-test.XXXXXXXX"` || exit
|
|
trap 'rm -rf "${T}"' 0
|
|
PATH=$T:$PATH
|
|
ls -ld . >/dev/null
|
|
cat <<EOF >"$T/ls"
|
|
:
|
|
EOF
|
|
chmod 755 "$T/ls"
|
|
PATH=$PATH
|
|
ls -ld .
|