git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: "Nguyễn Thái Ngọc Duy" <pclouds@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: [PATCH 3/3] Convert all fnmatch() calls to wildmatch()
Date: Wed, 19 Dec 2012 10:36:32 -0800	[thread overview]
Message-ID: <7v8v8tanyn.fsf@alter.siamese.dyndns.org> (raw)
In-Reply-To: <1355922488-20976-4-git-send-email-pclouds@gmail.com> ("Nguyễn	Thái Ngọc Duy"'s message of "Wed, 19 Dec 2012 20:08:08 +0700")

Nguyễn Thái Ngọc Duy  <pclouds@gmail.com> writes:

> diff --git a/tree-walk.c b/tree-walk.c
> index 492c7cd..c729e89 100644
> --- a/tree-walk.c
> +++ b/tree-walk.c
> @@ -3,6 +3,7 @@
>  #include "unpack-trees.h"
>  #include "dir.h"
>  #include "tree.h"
> +#include "wildmatch.h"
>  
>  static const char *get_mode(const char *str, unsigned int *modep)
>  {
> @@ -627,7 +628,7 @@ enum interesting tree_entry_interesting(const struct name_entry *entry,
>  				return entry_interesting;
>  
>  			if (item->use_wildcard) {
> -				if (!fnmatch(match + baselen, entry->path, 0))
> +				if (!wildmatch(match + baselen, entry->path, 0))
>  					return entry_interesting;

This and the change to dir.c obviously have interactions with
8c6abbc (pathspec: apply "*.c" optimization from exclude,
2012-11-24).

I've already alluded to it in my response to 2/3, I guess.

  reply	other threads:[~2012-12-19 18:36 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-12-19 13:08 [PATCH/WIP 0/3] Bye bye fnmatch() Nguyễn Thái Ngọc Duy
2012-12-19 13:08 ` [PATCH 1/3] wildmatch: make dowild() take arbitrary flags Nguyễn Thái Ngọc Duy
2012-12-19 16:32   ` Junio C Hamano
2012-12-19 13:08 ` [PATCH 2/3] wildmatch: support "no FNM_PATHNAME" mode Nguyễn Thái Ngọc Duy
2012-12-19 17:24   ` Junio C Hamano
2012-12-20  1:55     ` Nguyen Thai Ngoc Duy
2012-12-20 13:34       ` Nguyen Thai Ngoc Duy
2012-12-19 13:08 ` [PATCH 3/3] Convert all fnmatch() calls to wildmatch() Nguyễn Thái Ngọc Duy
2012-12-19 18:36   ` Junio C Hamano [this message]
2012-12-20 12:36     ` Nguyen Thai Ngoc Duy
2012-12-19 13:21 ` [PATCH/WIP 0/3] Bye bye fnmatch() Nguyen Thai Ngoc Duy

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7v8v8tanyn.fsf@alter.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=pclouds@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).