Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
cache_tree_find(): remove redundant check
author
Michael Haggerty
<mhagger@alum.mit.edu>
Wed, 5 Mar 2014 17:26:28 +0000
(18:26 +0100)
committer
Junio C Hamano
<gitster@pobox.com>
Wed, 5 Mar 2014 20:33:53 +0000
(12:33 -0800)
If *slash == '/', then it is necessarily non-NUL.
Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
cache-tree.c
patch
|
blob
|
history
raw
|
patch
| inline |
side by side
(parent:
79192b8
)
diff --git
a/cache-tree.c
b/cache-tree.c
index 408ee57a5070d9ec307723cb17493fceb9b4b28b..39ad8c99418b163857611c2de69b029abadb6237 100644
(file)
--- a/
cache-tree.c
+++ b/
cache-tree.c
@@
-563,7
+563,7
@@
static struct cache_tree *cache_tree_find(struct cache_tree *it, const char *pat
if (!sub)
return NULL;
it = sub->cache_tree;
- while (*slash
&& *slash
== '/')
+ while (*slash == '/')
slash++;
if (!*slash)
return it; /* prefix ended with slashes */