aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenis Vlasenko <vda.linux@googlemail.com>2008-10-13 08:54:42 +0000
committerDenis Vlasenko <vda.linux@googlemail.com>2008-10-13 08:54:42 +0000
commitd29084dd7d23cb0efe0732b22aa669adcc5eaa0e (patch)
tree2cdc8b5a964e9bf0bbb73f7d219328780191dd11
parent22d10a029283b93c31890366a1f8dcfc59e6298c (diff)
downloadbusybox-w32-d29084dd7d23cb0efe0732b22aa669adcc5eaa0e.tar.gz
busybox-w32-d29084dd7d23cb0efe0732b22aa669adcc5eaa0e.tar.bz2
busybox-w32-d29084dd7d23cb0efe0732b22aa669adcc5eaa0e.zip
testcase for the last fix
-rw-r--r--shell/hush_test/hush-vars/var_preserved.right4
-rwxr-xr-xshell/hush_test/hush-vars/var_preserved.tests16
2 files changed, 20 insertions, 0 deletions
diff --git a/shell/hush_test/hush-vars/var_preserved.right b/shell/hush_test/hush-vars/var_preserved.right
new file mode 100644
index 000000000..b0def4bb6
--- /dev/null
+++ b/shell/hush_test/hush-vars/var_preserved.right
@@ -0,0 +1,4 @@
1a=a
2a=a
3a=a
4OK
diff --git a/shell/hush_test/hush-vars/var_preserved.tests b/shell/hush_test/hush-vars/var_preserved.tests
new file mode 100755
index 000000000..132d387b4
--- /dev/null
+++ b/shell/hush_test/hush-vars/var_preserved.tests
@@ -0,0 +1,16 @@
1export a=a
2
3# external program
4a=b /bin/true
5env | grep ^a=
6
7# builtin
8a=b true
9env | grep ^a=
10
11# exec with redirection only
12# in bash, this leaks!
13a=b exec 1>&1
14env | grep ^a=
15
16echo OK