git/odb
Justin Tobler 8a1f5ecf28 object-file: remove flags from transaction packfile writes
The `index_blob_packfile_transaction()` function handles streaming a
blob from an fd to compute its object ID and conditionally writes the
object directly to a packfile if the INDEX_WRITE_OBJECT flag is set. A
subsequent commit will make these packfile object writes part of the
transaction interface. Consequently, having the object write be
conditional on this flag is a bit awkward.

In preparation for this change, introduce a dedicated
`hash_blob_stream()` helper that only computes the OID from a `struct
odb_write_stream`. This is invoked by `index_fd()` instead when the
INDEX_WRITE_OBJECT is not set. The object write performed via
`index_blob_packfile_transaction()` is made unconditional accordingly.

Signed-off-by: Justin Tobler <jltobler@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2026-05-15 04:44:40 +09:00
..
source-files.c odb/source: introduce generic object counting 2026-03-12 08:38:42 -07:00
source-files.h odb/source: make `free()` function pluggable 2026-03-05 11:45:15 -08:00
source.c odb/source: make `free()` function pluggable 2026-03-05 11:45:15 -08:00
source.h odb/source: introduce generic object counting 2026-03-12 08:38:42 -07:00
streaming.c object-file: remove flags from transaction packfile writes 2026-05-15 04:44:40 +09:00
streaming.h object-file: remove flags from transaction packfile writes 2026-05-15 04:44:40 +09:00
transaction.c odb/transaction: use pluggable `begin_transaction()` 2026-05-15 04:44:39 +09:00
transaction.h odb: split `struct odb_transaction` into separate header 2026-05-15 04:44:39 +09:00