summaryrefslogtreecommitdiff
path: root/checkout-index.c
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2005-12-13 21:39:56 -0800
committerJunio C Hamano <junkio@cox.net>2005-12-13 21:39:56 -0800
commitf4f9adaea7e4e46337ae8312f34228a743f0cd89 (patch)
treefec657e7dd2f594a47cbb3440d3e50a82b52dea9 /checkout-index.c
parented24928e122bad83e62d161087f806fa21c46a59 (diff)
downloadgit-f4f9adaea7e4e46337ae8312f34228a743f0cd89.tar.gz
checkout-index: fix checking out specific path.
3bd348aeea24709cd9be4b9d741f79b6014cd7e3 commit broke checking out specific paths. Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'checkout-index.c')
-rw-r--r--checkout-index.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/checkout-index.c b/checkout-index.c
index 1e1c9727e0..53dd8cba6f 100644
--- a/checkout-index.c
+++ b/checkout-index.c
@@ -58,7 +58,7 @@ static int checkout_file(const char *name)
while (pos < active_nr) {
struct cache_entry *ce = active_cache[pos];
- if (ce_namelen(ce) != namelen &&
+ if (ce_namelen(ce) != namelen ||
memcmp(ce->name, name, namelen))
break;
has_same_name = 1;