diff options
| author | Junio C Hamano <gitster@pobox.com> | 2020-04-28 15:50:04 -0700 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2020-04-28 15:50:04 -0700 |
| commit | 8f5dc5a4af3fa32bf9261b76b0f1146fd15b8643 (patch) | |
| tree | 0c93139e94d1964edec168d2cf02f6c0e1298b6d /builtin/index-pack.c | |
| parent | Merge branch 'js/subtree-doc-update-to-asciidoctor-2' (diff) | |
| parent | diff: restrict when prefetching occurs (diff) | |
| download | git-8f5dc5a4af3fa32bf9261b76b0f1146fd15b8643.tar.gz git-8f5dc5a4af3fa32bf9261b76b0f1146fd15b8643.zip | |
Merge branch 'jt/avoid-prefetch-when-able-in-diff'
"git diff" in a partial clone learned to avoid lazy loading blob
objects in more casese when they are not needed.
* jt/avoid-prefetch-when-able-in-diff:
diff: restrict when prefetching occurs
diff: refactor object read
diff: make diff_populate_filespec_options struct
promisor-remote: accept 0 as oid_nr in function
Diffstat (limited to 'builtin/index-pack.c')
| -rw-r--r-- | builtin/index-pack.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/builtin/index-pack.c b/builtin/index-pack.c index d967d188a3..f176dd28c8 100644 --- a/builtin/index-pack.c +++ b/builtin/index-pack.c @@ -1368,9 +1368,8 @@ static void fix_unresolved_deltas(struct hashfile *f) continue; oid_array_append(&to_fetch, &d->oid); } - if (to_fetch.nr) - promisor_remote_get_direct(the_repository, - to_fetch.oid, to_fetch.nr); + promisor_remote_get_direct(the_repository, + to_fetch.oid, to_fetch.nr); oid_array_clear(&to_fetch); } |
