summaryrefslogtreecommitdiff
path: root/sha1_file.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2018-03-21 11:30:10 -0700
committerJunio C Hamano <gitster@pobox.com>2018-03-21 11:30:10 -0700
commit649406644dc94caec3e3f2499a1786daffd90231 (patch)
treee3d8a3ded8fa5d375fd409506b22eb7960f91d78 /sha1_file.c
parentbeb2cdf5041104a7513301a9b20944a617eec94e (diff)
parent2b7750c923636b75d74936089af0a0a68f5b1596 (diff)
downloadgit-649406644dc94caec3e3f2499a1786daffd90231.tar.gz
Merge branch 'jh/fsck-promisors'
A hotfix to a topic that graduated recently. * jh/fsck-promisors: sha1_file: restore OBJECT_INFO_QUICK functionality
Diffstat (limited to 'sha1_file.c')
-rw-r--r--sha1_file.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/sha1_file.c b/sha1_file.c
index 1b94f39c4c..cc0f43ea84 100644
--- a/sha1_file.c
+++ b/sha1_file.c
@@ -1267,9 +1267,11 @@ int sha1_object_info_extended(const unsigned char *sha1, struct object_info *oi,
return 0;
/* Not a loose object; someone else may have just packed it. */
- reprepare_packed_git();
- if (find_pack_entry(real, &e))
- break;
+ if (!(flags & OBJECT_INFO_QUICK)) {
+ reprepare_packed_git();
+ if (find_pack_entry(real, &e))
+ break;
+ }
/* Check if it is a missing object */
if (fetch_if_missing && repository_format_partial_clone &&