Re: [PATCH v6 2/5] reflog-walk: expose read_complete_reflog

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Phillip Wood <phillip.wood123@xxxxxxxxx> writes:

> On 22/05/2025 19:55, brian m. carlson wrote:
>> In a future commit, we'll use this function and the corresponding free
>> function to read the entire reflog.  Expose it in the header so we can
>> do so.
>
> We already have refs_for_each_reflog_entry() and
> refs_for_each_reflog_entry_reverse() for traversing the reflog entries
> so I'm a bit confused as to why we need to make the internal details
> public.

The suggestion for using this function is largely fault of mine, who
did not think of using the for-each helpers.

Looking at the function signature of for-each-reflog-ent callback

        typedef int each_reflog_ent_fn(
                        struct object_id *old_oid, struct object_id *new_oid,
                        const char *committer, timestamp_t timestamp,
                        int tz, const char *msg, void *cb_data);

I think it gives us the same piece of information, and is
preferrable.

Thanks for a dose of sanity.




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux