Re: Positional parameter/Array slicing bug with empty arguments
From:
Chet Ramey
Subject:
Re: Positional parameter/Array slicing bug with empty arguments
Date:
Sun, 12 Jan 2014 19:03:47 -0500
User-agent:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:24.0) Gecko/20100101 Thunderbird/24.2.0
On 1/11/14, 7:01 PM, Theodoros V. Kalamatianos wrote:
> Hi,
>
> I have bumped into a rather strange issue:
>
> $ set -- ''; printf "=%s=\n" "$@" x
> ==
> =x=
> $ set -- ''; printf "=%s=\n" "${@:1}" x
> =x=
>
[...]
>
> I encountered this on bash-4.2.037, as provided by the Mageia 3 Linux
> distribution, but according to a contact on IRC, this issue also affects
> the latest patch (4.2.045).
Thanks for the report. This will be fixed in bash-4.3.
Chet
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU chet@case.edu http://cnswww.cns.cwru.edu/~chet/