summaryrefslogtreecommitdiff
path: root/builtin/commit-graph.c
diff options
context:
space:
mode:
authorMeet Soni <meetsoni3017@gmail.com>2025-03-19 20:59:26 +0530
committerJunio C Hamano <gitster@pobox.com>2025-03-21 01:51:07 -0700
commit9ce297239b94ca6bc671b629246711d0ebf096ef (patch)
treedc3f6922fc10f97cedce765b3ce012c04f001f28 /builtin/commit-graph.c
parent27571684ddca217d65c5f39947f20b9f5ec91863 (diff)
reftable: adapt writer_add_record() to propagate block_writer_add() errors
Previously, writer_add_record() would flush the current block and retry appending the record whenever block_writer_add() returned any nonzero error. This forced an assumption that every failure meant the block was full, even when errors such as memory allocation or I/O failures occurred. Update the writer_add_record() to inspect the error code returned by block_writer_add() and only flush and reinitialize the writer when the error is REFTABLE_ENTRY_TOO_BIG_ERROR. For any other error, immediately propagate it. Signed-off-by: Meet Soni <meetsoni3017@gmail.com> Acked-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/commit-graph.c')
0 files changed, 0 insertions, 0 deletions