From 4d902ea9def573cd15271177abbfa50fbf30c84f Mon Sep 17 00:00:00 2001 From: Denys Vlasenko Date: Fri, 2 Jul 2021 22:28:51 +0200 Subject: awk: fix beavior of "exit" without parameter function old new delta evaluate 3336 3339 +3 awk_exit 93 94 +1 awk_main 829 827 -2 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 2/1 up/down: 4/-2) Total: 2 bytes Signed-off-by: Denys Vlasenko --- testsuite/awk.tests | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'testsuite') diff --git a/testsuite/awk.tests b/testsuite/awk.tests index 3c230393f..770d8ffce 100755 --- a/testsuite/awk.tests +++ b/testsuite/awk.tests @@ -445,4 +445,9 @@ testing 'awk $NF is empty' \ '' \ 'a=====123=' +testing "awk exit N propagates through END's exit" \ + "awk 'BEGIN { exit 42 } END { exit }'; echo \$?" \ + "42\n" \ + '' '' + exit $FAILCOUNT -- cgit v1.2.3