summaryrefslogtreecommitdiff
path: root/resolve-undo.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2014-02-27 22:01:15 (GMT)
committerJunio C Hamano <gitster@pobox.com>2014-02-27 22:01:15 (GMT)
commitcbaeafc3251d08b479c5eb735444bb6ad6210c93 (patch)
tree5513bd0aab1246167f737639e72022c0de64b1a6 /resolve-undo.c
parent156d6ed9221ff38c4cd3bfcfc6778e31c104fd9b (diff)
parent2e70c01799bf663cc1fa5f6e37e025000ffdc0b0 (diff)
downloadgit-cbaeafc3251d08b479c5eb735444bb6ad6210c93.zip
git-cbaeafc3251d08b479c5eb735444bb6ad6210c93.tar.gz
git-cbaeafc3251d08b479c5eb735444bb6ad6210c93.tar.bz2
Merge branch 'nd/submodule-pathspec-ending-with-slash'
Allow "git cmd path/", when the 'path' is where a submodule is bound to the top-level working tree, to match 'path', despite the extra and unnecessary trailing slash. * nd/submodule-pathspec-ending-with-slash: clean: use cache_name_is_other() clean: replace match_pathspec() with dir_path_match() pathspec: pass directory indicator to match_pathspec_item() match_pathspec: match pathspec "foo/" against directory "foo" dir.c: prepare match_pathspec_item for taking more flags pathspec: rename match_pathspec_depth() to match_pathspec() pathspec: convert some match_pathspec_depth() to dir_path_match() pathspec: convert some match_pathspec_depth() to ce_path_match()
Diffstat (limited to 'resolve-undo.c')
-rw-r--r--resolve-undo.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/resolve-undo.c b/resolve-undo.c
index 49ebaaf..44c697c 100644
--- a/resolve-undo.c
+++ b/resolve-undo.c
@@ -185,7 +185,7 @@ void unmerge_index(struct index_state *istate, const struct pathspec *pathspec)
for (i = 0; i < istate->cache_nr; i++) {
const struct cache_entry *ce = istate->cache[i];
- if (!match_pathspec_depth(pathspec, ce->name, ce_namelen(ce), 0, NULL))
+ if (!ce_path_match(ce, pathspec, NULL))
continue;
i = unmerge_index_entry_at(istate, i);
}