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
diff options
context:
space:
mode:
Diffstat (limited to 'diffcore-pathspec.c')
-rw-r--r--diffcore-pathspec.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/diffcore-pathspec.c b/diffcore-pathspec.c
index a48acbc965..68fe009132 100644
--- a/diffcore-pathspec.c
+++ b/diffcore-pathspec.c
@@ -29,6 +29,8 @@ static int matches_pathspec(const char *name, struct path_spec *s, int cnt)
name[len] == 0 ||
name[len] == '/')
return 1;
+ if (!len)
+ return 1;
}
return 0;
}