]> git.ipfire.org Git - thirdparty/bash.git/blobdiff - tests/exec9.sub
Bash-4.2 distribution sources and documentation
[thirdparty/bash.git] / tests / exec9.sub
diff --git a/tests/exec9.sub b/tests/exec9.sub
new file mode 100644 (file)
index 0000000..b8d20b4
--- /dev/null
@@ -0,0 +1,20 @@
+# make sure commands before the last one in the pipeline can't change $?
+false
+false | echo $?
+false
+(false) | echo $?
+
+false
+true | echo $?
+false
+(true) | echo $?
+
+true
+false | echo $?
+true
+(false) | echo $?
+
+true
+true | echo $?
+true
+(true) | echo $?