From a124da3a4a4bf6e91a567033e1e03241d9d0faa9 Mon Sep 17 00:00:00 2001 From: Bart Schaefer Date: Sun, 9 Dec 2007 23:53:33 +0000 Subject: 24150: Exit status of null command should be exit status of last cmdsubst. --- Test/D08cmdsubst.ztst | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'Test/D08cmdsubst.ztst') diff --git a/Test/D08cmdsubst.ztst b/Test/D08cmdsubst.ztst index 6cbcbf929..015796ed6 100644 --- a/Test/D08cmdsubst.ztst +++ b/Test/D08cmdsubst.ztst @@ -81,3 +81,11 @@ >third: file1.txt file2.txt >fourth: * >fifth: file1.txt file2.txt + + $(exit 0) $(exit 3) || print $? +0:empty command uses exit value of last substitution +>3 + + X=$(exit 2) $(exit 0) || print $? +0:variable assignments processed after other substitutions +>2 -- cgit 1.4.1