Re: [PATCH] Simplify alias storage.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Apr 25, 2024 at 09:46:45PM +0100, Harald van Dijk wrote:
>
> You're quite right, thanks for spotting that. A test case that covers that
> is
> 
>   alias foo='
>   alias foo="echo Hello"
>   '
>   foo
>   foo
> 
> Here, the storage of the original 'foo' alias needs to be kept while the
> expansion is ongoing, even when the second 'alias' overwrites the original
> definition. This bug is fixed by below additional patch.

Could you please post a combined patch? Thanks!

> However, the patch conflicts with c8db655b because scanning 'name' will now
> find the '=' character and continue on from that to check the value. That
> should be relatively easy to avoid, but I am not sure it is worth it.

Don't worry about that one.  I can back it out if necessary.
In fact, I'll probably fix it in a different way as I'm adding
multi-byte support.

Cheers,
-- 
Email: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt




[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux