[prev in list] [next in list] [prev in thread] [next in thread]
List: bash-bug
Subject: Re: Bug with -o posix, local variables and assignment preceding builtins
From: Crestez Dan Leonard <cdleonard () gmail ! com>
Date: 2010-02-10 10:25:18
Message-ID: 1265797518.27684.48.camel () deskbox
[Download RAW message or body]
On Mon, 2010-02-08 at 17:38 -0500, Chet Ramey wrote:
> On 2/7/10 8:33 PM, Crestez Dan Leonard wrote:
> > We encountered a strange bug while working on bash-completion. I was
> > originally only able to reproduce this through a fairly elaborate setup
> > but Freddy Vulto <fvulto@gmail.com> found a tiny test case:
> >
> > set -o posix
> > t() {
> > local x
> > BAR=a eval true
> > }
> > BAR=b; t; echo $BAR
> >
> > Bash documentation claims the following (section 6.11 point 23):
>
> See if the attached patch does the trick.
>
> Chet
Yes, it now works correctly. I tested both the simple example above and
my initial testing setup.
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic