Re: global-buffer-overflow in parse.y

2023-03-17 Thread Chet Ramey
On 3/16/23 6:10 PM, Grisha Levit wrote: On Mon, Mar 6, 2023 at 9:16 AM Chet Ramey wrote: Thanks for the report. It's the specific combination of `if' and the `((' command that causes the problem. Looks like same thing also happens when `if' is followed by a newline Thanks for the report. -

Re: global-buffer-overflow in parse.y

2023-03-16 Thread Grisha Levit
On Mon, Mar 6, 2023 at 9:16 AM Chet Ramey wrote: > Thanks for the report. It's the specific combination of `if' and the `((' > command that causes the problem. Looks like same thing also happens when `if' is followed by a newline ./bash -c $'case $LINENO in 0) if\n:; then echo FAIL; fi esac' bas

Re: global-buffer-overflow in parse.y

2023-03-06 Thread Chet Ramey
On 3/3/23 2:22 AM, Grisha Levit wrote: $ ./bash -c 'case x in x) if ((1)); then :; fi ;; esac' parse.y:974:82: runtime error: index -1 out of bounds for type 'int[257]' SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior parse.y:974:82 in ==

global-buffer-overflow in parse.y

2023-03-02 Thread Grisha Levit
$ ./bash -c 'case x in x) if ((1)); then :; fi ;; esac' parse.y:974:82: runtime error: index -1 out of bounds for type 'int[257]' SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior parse.y:974:82 in = ==52960==ERROR: AddressSaniti