busybox/shell/hush_test
Denys Vlasenko 9ee5892798 ash: expand: Fix trailing newlines processing in backquote expanding
Upstream commit:

    Date: Mon, 29 Apr 2019 19:13:37 +0500
    expand: Fix trailing newlines processing in backquote expanding

    According to POSIX.1-2008 we should remove newlines only at the end of
    the substitution. Newlines-only substitions causes dash to remove
    newlines before beggining of the substitution. The following code:

        cat <<END
        1
        $(echo "")
        2
        END

    prints "1<newline>2" instead of expected "1<newline><newline>2".

    This patch fixes trailing newlines processing in backquote expanding.

    Signed-off-by: Nikolai Merinov <n.merinov@inango-systems.com>
    Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2020-02-17 10:24:32 +01:00
..
hush-arith ash: parser: Add syntax stack for recursive parsing 2018-04-02 13:15:37 +02:00
hush-bugs hush: fix and_or_and_backgrounding.tests failure 2017-07-15 22:51:55 +02:00
hush-getopts hush: fix "getopts" builtin to not be upset by other builtins calling getopt() 2017-08-29 13:38:30 +02:00
hush-glob ash: expand: Do not quote backslashes in unquoted parameter expansion 2018-08-07 18:58:02 +02:00
hush-heredoc hush: add "heredoc.tests" from ash, tweak ash "is a function" message 2018-07-24 17:10:18 +02:00
hush-invert
hush-leak
hush-misc shells: add tests for backslashes in export VAR=VAL 2019-05-14 19:15:20 +02:00
hush-parsing hush: fix recent breakage from parse_stream() changes 2018-04-11 20:00:43 +02:00
hush-psubst ash: expand: Fix trailing newlines processing in backquote expanding 2020-02-17 10:24:32 +01:00
hush-quoting hush: adopt ash's quote_in_varexp1.tests 2018-08-05 20:03:04 +02:00
hush-read hush: fix IFS handling in read 2018-04-11 17:18:34 +02:00
hush-redir hush: restore redirected stdin 2019-11-01 14:16:07 +01:00
hush-signals
hush-standalone ash: fix nofork bug where environment is not properly passed to a command 2017-11-03 14:16:25 +01:00
hush-vars ash: parser: Only accept single-digit parameter expansion outside of braces 2020-02-17 10:15:35 +01:00
hush-z_slow hush: improve ${var#...}, ${var:+...} and ${var/.../...} - handle quoting 2018-07-17 14:21:38 +02:00
.gitignore
run-all nofork: fix a bug uncovered by hush testsuite (forgotten fflush) 2017-08-03 19:52:47 +02:00