reftable/record: improve semantics when initializing records
commit3ddef475d008b8a705a53e6bb1405bb773ffdc50
authorPatrick Steinhardt <ps@pks.im>
Tue, 6 Feb 2024 06:35:59 +0000 (6 07:35 +0100)
committerJunio C Hamano <gitster@pobox.com>
Tue, 6 Feb 2024 20:10:09 +0000 (6 12:10 -0800)
tree1185254dfc15585b9504efc09b6f8a0e0b70eddd
parent62d3c8e8c8a3dc3113cead8d9dd36f7e59054670
reftable/record: improve semantics when initializing records

According to our usual coding style, the `reftable_new_record()`
function would indicate that it is allocating a new record. This is not
the case though as the function merely initializes records without
allocating any memory.

Replace `reftable_new_record()` with a new `reftable_record_init()`
function that takes a record pointer as input and initializes it
accordingly.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
reftable/block.c
reftable/merged.c
reftable/reader.c
reftable/record.c
reftable/record.h
reftable/record_test.c