Re: [PATCH 1/5] check-ignore: move setup into cmd_check_ignore()
- From
Jeff King <peff@peff.net>
- Date
- Apr 11, 2013, 18:35 UTC
- Message-ID
- <20130411183518.GB3177@sigill.intra.peff.net>
- In-Reply-To
- <20130411110511.GB24296@pacific.linksys.moosehall>
On Thu, Apr 11, 2013 at 12:05:11PM +0100, Adam Spiers wrote:
Show 12 quoted lines
> On Thu, Apr 11, 2013 at 01:25:53AM -0400, Jeff King wrote: > > On Thu, Apr 11, 2013 at 02:59:31AM +0100, Adam Spiers wrote: > > > -static int check_ignore(const char *prefix, const char **pathspec) > > > +static int check_ignore(struct path_exclude_check check, > > > + const char *prefix, const char **pathspec) > > > > Did you mean to pass the struct by value here? If it is truly a per-path > > [...] > > It's not a per-path value; it's supposed to be reused across checks > for multiple paths, as explained in the comments above > last_exclude_matching_path():
Makes sense (I didn't look into it very far, and was just guessing based on the pass-by-value). Passing a pointer is definitely the right fix, then.
Thanks.
-Peff