summaryrefslogtreecommitdiff
path: root/contrib/persistent-https
diff options
context:
space:
mode:
authorJustin Tobler <jltobler@gmail.com>2026-07-10 11:37:17 -0500
committerJunio C Hamano <gitster@pobox.com>2026-07-10 13:21:53 -0700
commit4576d6c5225fec402fa8d4190abb63e6f938b98d (patch)
treed4abbf7ed0ab8adcd13d2daabac5950f07940e00 /contrib/persistent-https
parent6d017185e3b4052354fca3a40e8453bd85624896 (diff)
odb/transaction: propagate begin errors
When `odb_transaction_begin()` is invoked, the function returns the transaction pointer directly. There is no way for the backend to signal that it failed to set up its state, such as when creating the temporary object directory backing the transaction. In a subsequent commit, git-receive-pack(1) starts using ODB transactions and needs to be able to report such failures rather than silently ignore them. Refactor `odb_transaction_begin()` to return an int error code and write the resulting transaction into an out parameter. Also introduce `odb_transaction_begin_or_die()` as a convenience for callsites that do not need to handle errors explicitly. Note that `odb_transaction_begin()` now returns an error when the ODB already has an inflight transaction pending. ODB transaction call sites that may encounter an inflight transaction are updated to explicitly handle this case. Signed-off-by: Justin Tobler <jltobler@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'contrib/persistent-https')
0 files changed, 0 insertions, 0 deletions