On 12/4/23 2:24 PM, Giacomo Comes wrote:

The script I was using was more complicated.
I did simplify it and I tested the simpler version only with bash 5.0, assuming
it would fail with 5.1 and 5.2 too.
The following one fails with every 5.x version:
------------------------------------------------
#!/bin/bash

if ((1)); then
         ( : ) | : ; echo 1 $LINENO
fi
echo 2 $LINENO
------------------------------------------------
Need to add a pipe after the subshell command.

Thanks for the updated example. There are several fixes in the devel
branch regarding LINENO.

This particular issue was fixed back in September, 2022 as the result of

https://savannah.gnu.org/support/index.php?110714

Chet
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    c...@case.edu    http://tiswww.cwru.edu/~chet/

Attachment: OpenPGP_signature.asc
Description: OpenPGP digital signature

Reply via email to