Commits


fix pack checksum handling for sha256


add field to got_packidx to propagate the hash algo allows to drop all the `algo' hardcodings in lib/pack.c and pack_idx.c


handle both sha1 and sha256 object ids in pack files bump got_packidx_object_id so it can hold a sha256 digest and adapt the code to read the needed type of hash.


add an hash algo field to got_pack - maybe useless


adjust GOT_PACKIDX_NAMELEN for sha256 packs


rename pack{file,idx}_sha1 to _hash


rename "sha1" field to "hash" done with X ,x/\.sha1/c/hash X ,x/->sha1/c/->hash in sam after loading all the C files; except for one manual tweak in hash.c


avoid copying reused deltas to delta cache file; copy from pack file instead ok op@


convert got_pack' filesize to off_t; ok stsp@


change got_pack_parse_offset_delta tslen argument to size_t The tslen argument is always in the (1..9) range so `int' is technically fine (even int8_t would be!) but all the callers are passing a size_t, so change the type accordingly. ok stsp@


move declaration of got_privsep_child out of got_lib_privsep.h This declaration is the only reason why got_lib_privsep.h must be included in order to use got_lib_repository.h. Moving this declaration will allow for cleaning up unnecessary includes of got_lib_privsep.h.


remove trailing whitespace; patch by Josiah Frentsos


implement support for commit coloring in got-read-pack for speed ok op, tracey


allow start_pack_privsep_child() to be called from outside lib/object.c


open temporary files needed for delta application in got_repo_open() This prepares for callers of got_repo_open() that cannot afford to open files in /tmp, such as gotwebd. In a follow-up change, we could ask such callers to pass in the required amount of open temporary files. One consequence is that got_repo_open() now requires the "cpath" pledge promise. Add the "cpath" promise to affected callers and remove it once the repository has been opened. ok tracey