pathspec: convert some match_pathspec_depth() to ce_path_match()
This helps reduce the number of match_pathspec_depth() call sites and show how match_pathspec_depth() is used. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
017f804efc
commit
429bb40abd
@ -12,6 +12,7 @@
|
||||
#include "resolve-undo.h"
|
||||
#include "parse-options.h"
|
||||
#include "pathspec.h"
|
||||
#include "dir.h"
|
||||
|
||||
/*
|
||||
* Default to not allowing changes to the list of files. The
|
||||
@ -564,7 +565,7 @@ static int do_reupdate(int ac, const char **av,
|
||||
struct cache_entry *old = NULL;
|
||||
int save_nr;
|
||||
|
||||
if (ce_stage(ce) || !ce_path_match(ce, &pathspec))
|
||||
if (ce_stage(ce) || !ce_path_match(ce, &pathspec, NULL))
|
||||
continue;
|
||||
if (has_head)
|
||||
old = read_one_ent(NULL, head_sha1,
|
||||
|
Reference in New Issue
Block a user