Re: heap-use-after-free in executing_line_number

2024-02-02 Thread Chet Ramey
On 1/25/24 3:23 AM, Grisha Levit wrote: If currently_executing_command was a subshell, it can end up freed by the time executing_line_number checks it. Thanks for the report. The fix is to have function_substitute save and restore this, since parse_and_execute can overwrite it. Chet -- ``The

heap-use-after-free in executing_line_number

2024-01-25 Thread Grisha Levit
If currently_executing_command was a subshell, it can end up freed by the time executing_line_number checks it. $ bash-asan -c '${ (:); }/' = ERROR: AddressSanitizer: heap-use-after-free on address 0x000106208a40 at pc 0x000102c8bf38