From 640118e781d9687ba2f2664629fe205ec081479f Mon Sep 17 00:00:00 2001 From: ridiculousfish Date: Sun, 16 Jun 2013 23:26:43 -0700 Subject: Cleanup of code that decides whether or not to fork. Fix for issue where stderr may be output twice. --- tests/test9.in | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'tests/test9.in') diff --git a/tests/test9.in b/tests/test9.in index b8842727..a38fbc7c 100644 --- a/tests/test9.in +++ b/tests/test9.in @@ -1,5 +1,14 @@ +# ensure that builtins that produce no output can still truncate files +# (bug PCA almost reintroduced!) +echo "Testing that builtins can truncate files" +echo abc > /tmp/file_truncation_test.txt +cat /tmp/file_truncation_test.txt +echo -n > /tmp/file_truncation_test.txt +cat /tmp/file_truncation_test.txt + # Test events. + # This pattern caused a crash; github issue #449 set -g var before @@ -25,4 +34,4 @@ end emit test3 foo bar # test empty argument -emit \ No newline at end of file +emit -- cgit v1.2.3