aboutsummaryrefslogtreecommitdiffstats
path: root/commit-graph.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2025-11-04 07:31:26 -0800
committerJunio C Hamano <gitster@pobox.com>2025-11-04 07:31:26 -0800
commit8c6e6b27379b98269620f5f20397425ba358a1bb (patch)
treef5c35ea7c977e5ee3df8a3cbfb4b29a732d66e1a /commit-graph.c
parentRevert "Merge branch 'kn/refs-optim-cleanup' into next" (diff)
downloadgit-8c6e6b27379b98269620f5f20397425ba358a1bb.tar.gz
git-8c6e6b27379b98269620f5f20397425ba358a1bb.zip
Revert "Merge branch 'ps/ref-peeled-tags' into next"
This reverts commit 8ac48a10de61267858d66383c34833e55a5e9d02, reversing changes made to 9ab444edfb825dfbc555b3d7916df03071db94c3.
Diffstat (limited to 'commit-graph.c')
-rw-r--r--commit-graph.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/commit-graph.c b/commit-graph.c
index 80be2ff2c3..474454db73 100644
--- a/commit-graph.c
+++ b/commit-graph.c
@@ -1851,16 +1851,18 @@ struct refs_cb_data {
struct progress *progress;
};
-static int add_ref_to_set(const struct reference *ref, void *cb_data)
+static int add_ref_to_set(const char *refname UNUSED,
+ const char *referent UNUSED,
+ const struct object_id *oid,
+ int flags UNUSED, void *cb_data)
{
- const struct object_id *maybe_peeled = ref->oid;
struct object_id peeled;
struct refs_cb_data *data = (struct refs_cb_data *)cb_data;
- if (!reference_get_peeled_oid(data->repo, ref, &peeled))
- maybe_peeled = &peeled;
- if (odb_read_object_info(data->repo->objects, maybe_peeled, NULL) == OBJ_COMMIT)
- oidset_insert(data->commits, maybe_peeled);
+ if (!peel_iterated_oid(data->repo, oid, &peeled))
+ oid = &peeled;
+ if (odb_read_object_info(data->repo->objects, oid, NULL) == OBJ_COMMIT)
+ oidset_insert(data->commits, oid);
display_progress(data->progress, oidset_size(data->commits));