[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: nofork command substitution
From: |
Grisha Levit |
Subject: |
Re: nofork command substitution |
Date: |
Tue, 23 May 2023 16:17:19 -0400 |
An interactive shell gets confused (PS1 shown instead of PS2) when using
newline as the first character of the substitution:
$ bash --norc -i <<<$'${\n:;}'
bash-5.2$ ${
bash-5.2$ :;}
----
Things don't seem to work right with an empty funsub:
bash --pretty-print <<<'${ }'
${ ; }
$ bash -c '${ }'
ERROR: AddressSanitizer: heap-buffer-overflow
READ of size 1 at 0x005af9470f1f thread T0
#0 0x56ec06e390 in parse_comsub parse.y:4462:15
#1 0x56ec058344 in read_token_word parse.y:5294:16
#2 0x56ec04c144 in read_token parse.y:3642:12
I'm not sure if it makes sense to accept `${ }' (like `$( )') or not (like
`{ }'). FWIW, mksh accepts both.
- Re: nofork command substitution, (continued)
- Re: nofork command substitution, Grisha Levit, 2023/05/19
- Re: nofork command substitution, Koichi Murase, 2023/05/23
- Re: nofork command substitution, Chet Ramey, 2023/05/24
- Re: nofork command substitution, Robert Elz, 2023/05/25
- Re: nofork command substitution, Koichi Murase, 2023/05/25
- Re: nofork command substitution, Chet Ramey, 2023/05/25
- Re: nofork command substitution, Robert Elz, 2023/05/25
- Re: nofork command substitution, Chet Ramey, 2023/05/25
Re: nofork command substitution,
Grisha Levit <=
Re: nofork command substitution, Daniel Douglas, 2023/05/25
Fwd: Re: nofork command substitution, Chet Ramey, 2023/05/19