diff options
author | Junio C Hamano <gitster@pobox.com> | 2020-09-22 21:36:31 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2020-09-22 21:36:32 +0200 |
commit | 221b755f3a99f600d08441fc5436d0f2ffe57065 (patch) | |
tree | f0bdb3b7ae7592f3f2d5c128ec3826e5cbe9b5b4 /packfile.c | |
parent | Merge branch 'al/ref-filter-merged-and-no-merged' (diff) | |
parent | packfile: actually set approximate_object_count_valid (diff) | |
download | git-221b755f3a99f600d08441fc5436d0f2ffe57065.tar.xz git-221b755f3a99f600d08441fc5436d0f2ffe57065.zip |
Merge branch 'jk/dont-count-existing-objects-twice'
There is a logic to estimate how many objects are in the
repository, which is mean to run once per process invocation, but
it ran every time the estimated value was requested.
* jk/dont-count-existing-objects-twice:
packfile: actually set approximate_object_count_valid
Diffstat (limited to 'packfile.c')
-rw-r--r-- | packfile.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/packfile.c b/packfile.c index 9ef27508f2..e69012e7f2 100644 --- a/packfile.c +++ b/packfile.c @@ -923,6 +923,7 @@ unsigned long repo_approximate_object_count(struct repository *r) count += p->num_objects; } r->objects->approximate_object_count = count; + r->objects->approximate_object_count_valid = 1; } return r->objects->approximate_object_count; } |