Andrew's git
/
gitweb.git
/ blobdiff
summary
|
log
|
commit
|
diff
|
tree
commit
grep
author
committer
pickaxe
?
re
Merge branch 'nd/fetch-into-shallow' into maint
[gitweb.git]
/
sha1_file.c
diff --git
a/sha1_file.c
b/sha1_file.c
index 8e27db1bd2b49f28b235fcd7e18a0dda43a1f045..06784fb95af2ddbdbfc6ed97e6ccf2ac920393b3 100644
(file)
--- a/
sha1_file.c
+++ b/
sha1_file.c
@@
-2925,7
+2925,10
@@
int has_sha1_file(const unsigned char *sha1)
if (find_pack_entry(sha1, &e))
return 1;
- return has_loose_object(sha1);
+ if (has_loose_object(sha1))
+ return 1;
+ reprepare_packed_git();
+ return find_pack_entry(sha1, &e);
}
static void check_tree(const void *buf, size_t size)