summaryrefslogtreecommitdiff
path: root/sha1-file.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2019-04-25 07:41:19 (GMT)
committerJunio C Hamano <gitster@pobox.com>2019-04-25 07:41:19 (GMT)
commit32dc15dec1cd9e9fada2983094484ae6e4c93647 (patch)
tree625393be9fb971cf5c803d2ba3997a4741e4cbc7 /sha1-file.c
parentac70c5313351630e44b1fe0267fb4850ebcf1f25 (diff)
parent7fbbcb21b162883615d5542e06fb2eb8685fd496 (diff)
downloadgit-32dc15dec1cd9e9fada2983094484ae6e4c93647.zip
git-32dc15dec1cd9e9fada2983094484ae6e4c93647.tar.gz
git-32dc15dec1cd9e9fada2983094484ae6e4c93647.tar.bz2
Merge branch 'jt/batch-fetch-blobs-in-diff'
While running "git diff" in a lazy clone, we can upfront know which missing blobs we will need, instead of waiting for the on-demand machinery to discover them one by one. Aim to achieve better performance by batching the request for these promised blobs. * jt/batch-fetch-blobs-in-diff: diff: batch fetching of missing blobs sha1-file: support OBJECT_INFO_FOR_PREFETCH
Diffstat (limited to 'sha1-file.c')
-rw-r--r--sha1-file.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sha1-file.c b/sha1-file.c
index bcd9470..ed5c50d 100644
--- a/sha1-file.c
+++ b/sha1-file.c
@@ -1378,7 +1378,8 @@ int oid_object_info_extended(struct repository *r, const struct object_id *oid,
/* Check if it is a missing object */
if (fetch_if_missing && repository_format_partial_clone &&
- !already_retried && r == the_repository) {
+ !already_retried && r == the_repository &&
+ !(flags & OBJECT_INFO_FOR_PREFETCH)) {
/*
* TODO Investigate having fetch_object() return
* TODO error/success and stopping the music here.