Re: [PATCH 03/21] pathspec: make sure the prefix part is wildcard-clean

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

 



On Sun, Jan 6, 2013 at 1:20 PM, Nguyễn Thái Ngọc Duy <pclouds@xxxxxxxxx> wrote:
> --- a/setup.c
> +++ b/setup.c
> @@ -250,6 +250,8 @@ static unsigned prefix_pathspec(struct pathspec_item *item,
>         *raw = item->match;
>         item->len = strlen(item->match);
>         item->nowildcard_len = simple_length(item->match);
> +       if (item->nowildcard_len < prefixlen)
> +               item->nowildcard_len = prefixlen;
>         return magic;
>  }

This is wrong (so much for the last-minute patch). Prefix length
depends on actual pathspec (e.g. abc, ../abc and ../../abc use
different prefix length). This patch should be discarded (it does not
have any real impacts anyway).
-- 
Duy
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]