X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=checkout-index.c;h=957b4a86b07062b4cafaf9006bca6f7767b46ecf;hb=379156e1dc46e0d22f0c7c0c52913c6259c62258;hp=1e1c9727e0e8568e3e2768ceae8831e993f22b72;hpb=3bd348aeea24709cd9be4b9d741f79b6014cd7e3;p=git.git diff --git a/checkout-index.c b/checkout-index.c index 1e1c9727..957b4a86 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; @@ -116,6 +116,7 @@ int main(int argc, char **argv) int all = 0; prefix = setup_git_directory(); + git_config(git_default_config); prefix_length = prefix ? strlen(prefix) : 0; if (read_cache() < 0) {