Jim,
On Friday 06 April 2012 15:25:30 Jim Meyering wrote:
> +static void
> +add_bad (char *bad[], char const *name)
> +{
> + char **p = &bad[!! bad[0]];
we remember the first and last bad name here, not all the bad names of the
last patch (bad[0] is never cleared), so that's a bug.
I don't see the benefit of remembering all names; patches that modify the same
file more than once are pretty rare. So this approach doesn't look better
than the alternative to me. Thanks for offering that solution though!
> + say ("Ignoring potentially dangerous file name %s\n", quotearg (name));
> + free (*p);
> + *p = xstrdup (name);
> +}
Andreas