Andrew's git
/
gitweb.git
/ blobdiff
summary
|
log
|
commit
|
diff
|
tree
commit
grep
author
committer
pickaxe
?
re
builtin-commit.c: show on which branch a commit was added
[gitweb.git]
/
builtin-for-each-ref.c
diff --git
a/builtin-for-each-ref.c
b/builtin-for-each-ref.c
index 4d25ec51d009bf18f95c60ca9ccd641ac5792db6..21e92bbcb577c0361df51bd81e6fb5ab546619ea 100644
(file)
--- a/
builtin-for-each-ref.c
+++ b/
builtin-for-each-ref.c
@@
-652,7
+652,8
@@
static int grab_single_ref(const char *refname, const unsigned char *sha1, int f
if ((plen <= namelen) &&
!strncmp(refname, p, plen) &&
(refname[plen] == '\0' ||
- refname[plen] == '/'))
+ refname[plen] == '/' ||
+ p[plen-1] == '/'))
break;
if (!fnmatch(p, refname, FNM_PATHNAME))
break;