From e939856c8724e357b3a7ba878563bfc957605504 Mon Sep 17 00:00:00 2001 From: Ron Yorston Date: Fri, 30 Oct 2015 19:05:55 +0000 Subject: ash: add tests for failures of the exec and command builtins The exec builtin should return an exit status of 127 if the command can't be found. It doesn't: it returns 2. If the command builtin is used to source a script that runs a second script that doesn't exist ash should issue an error. Instead it seg faults. Signed-off-by: Ron Yorston Signed-off-by: Denys Vlasenko --- shell/ash_test/ash-misc/exec.right | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 shell/ash_test/ash-misc/exec.right (limited to 'shell/ash_test/ash-misc/exec.right') diff --git a/shell/ash_test/ash-misc/exec.right b/shell/ash_test/ash-misc/exec.right new file mode 100644 index 0000000..1741a38 --- /dev/null +++ b/shell/ash_test/ash-misc/exec.right @@ -0,0 +1,2 @@ +./exec.tests: exec: line 2: ./test1.sh: not found +127 -- cgit v1.1