Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tree.c
diff options
context:
space:
mode:
Diffstat (limited to 'tree.c')
-rw-r--r--tree.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/tree.c b/tree.c
index 0d703a0c47..5ab90af256 100644
--- a/tree.c
+++ b/tree.c
@@ -62,6 +62,7 @@ static int match_tree_entry(const char *base, int baselen, const char *path, uns
continue;
/* pathspecs match only at the directory boundaries */
if (!matchlen ||
+ baselen == matchlen ||
base[matchlen] == '/' ||
match[matchlen - 1] == '/')
return 1;