aboutsummaryrefslogtreecommitdiff
path: root/shell/hush_test
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2017-07-31 18:02:28 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2017-07-31 18:02:28 +0200
commit5b3d2eb327ce7e1c55c6c94bc70782f733d59990 (patch)
tree5e58b81282353c4cb6552bb6b44b336c28132f93 /shell/hush_test
parentd0fff9155bc55d9576be4c6ba5f656f5b4856ac4 (diff)
downloadbusybox-5b3d2eb327ce7e1c55c6c94bc70782f733d59990.tar.gz
hush: fix "true | func_with_return" not allowing return.
function old new delta pseudo_exec_argv 305 312 +7 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'shell/hush_test')
-rw-r--r--shell/hush_test/hush-misc/func_return1.right (renamed from shell/hush_test/hush-misc/func6.right)0
-rwxr-xr-xshell/hush_test/hush-misc/func_return1.tests (renamed from shell/hush_test/hush-misc/func6.tests)0
-rw-r--r--shell/hush_test/hush-misc/func_return2.right2
-rwxr-xr-xshell/hush_test/hush-misc/func_return2.tests6
4 files changed, 8 insertions, 0 deletions
diff --git a/shell/hush_test/hush-misc/func6.right b/shell/hush_test/hush-misc/func_return1.right
index 0ebd8e5a3..0ebd8e5a3 100644
--- a/shell/hush_test/hush-misc/func6.right
+++ b/shell/hush_test/hush-misc/func_return1.right
diff --git a/shell/hush_test/hush-misc/func6.tests b/shell/hush_test/hush-misc/func_return1.tests
index 029c3e85e..029c3e85e 100755
--- a/shell/hush_test/hush-misc/func6.tests
+++ b/shell/hush_test/hush-misc/func_return1.tests
diff --git a/shell/hush_test/hush-misc/func_return2.right b/shell/hush_test/hush-misc/func_return2.right
new file mode 100644
index 000000000..0ebd8e5a3
--- /dev/null
+++ b/shell/hush_test/hush-misc/func_return2.right
@@ -0,0 +1,2 @@
+Two:2
+Two:2
diff --git a/shell/hush_test/hush-misc/func_return2.tests b/shell/hush_test/hush-misc/func_return2.tests
new file mode 100755
index 000000000..a049dd180
--- /dev/null
+++ b/shell/hush_test/hush-misc/func_return2.tests
@@ -0,0 +1,6 @@
+f1() { return 2; }
+f1
+echo Two:$?
+false
+true | f1
+echo Two:$?