Re: [PATCH v4 4/7] builtin/repo: add inflated object info to keyvalue structure output
- From
Justin Tobler <jltobler@gmail.com>
- Date
- Dec 17, 2025, 16:10 UTC
- Message-ID
- <ygljaf4o7mgsvzz6upybtj3fslpdk7a5j3jz3lxjhho4is5cjf@o22or2lcvhep>
- In-Reply-To
- <aUJVyHOCsCjjazB-@pks.im>
On 25/12/17 08:03AM, Patrick Steinhardt wrote:
Show 24 quoted lines
> On Tue, Dec 16, 2025 at 11:38:39AM -0600, Justin Tobler wrote:
> > diff --git a/builtin/repo.c b/builtin/repo.c
> > index 9c61bc3e17..e207108346 100644
> > --- a/builtin/repo.c
> > +++ b/builtin/repo.c
> > @@ -495,20 +508,39 @@ static int count_objects(const char *path UNUSED, struct oid_array *oids,
> > {
> > struct count_objects_data *data = cb_data;
> > struct object_stats *stats = data->stats;
> > + size_t inflated_total = 0;
> > size_t object_count;
> >
> > + for (size_t i = 0; i < oids->nr; i++) {
> > + struct object_info oi = OBJECT_INFO_INIT;
> > + unsigned long inflated;
> > +
> > + oi.sizep = &inflated;
> > +
> > + if (odb_read_object_info_extended(data->odb, &oids->oid[i], &oi,
> > + OBJECT_INFO_SKIP_FETCH_OBJECT |
> > + OBJECT_INFO_QUICK) < 0)
>
> Tiny nit: there seems to be an extra tab here. This really is only worth
> fixing if you intend to reroll anyway.I had that initially, but it was failing the check_style CI job so I just opted to what clang format wanted. I can change it though if I sent another version. I haven't quite figured out the best way to wrap long lines.
-Justin