Re: [PATCH] fix shell bug in ${var%pattern} expansion

From: David O'Brien <obrien_at_freebsd.org>
Date: Wed, 13 Oct 2010 16:24:11 -0700
On Wed, Oct 13, 2010 at 11:42:48PM +0200, Jilles Tjoelker wrote:
> Style bug:
> > +growstrstackblock(int n) {
> The opening brace should be on its own line.

Indeed.  I'm surprised I did that.  Thank you for catching it.

> Your test is too fragile: it often fails to detect the bug. Calling like
>   sh -c '. expansion/trim4.0'
> gives the correct output even with a buggy sh. I propose something like
> this, or perhaps with an additional string comparison:

I also like this test better.

Thank you for the review.

-- 
-- David  (obrien_at_FreeBSD.org)
Received on Wed Oct 13 2010 - 21:24:12 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:08 UTC