Commits


refresh cached list of pack index paths while searching a packed object Previously, this list was only refreshed while trying to match an object ID prefix. Regular pack file access needs to refresh this list, too. In particular, future gotd(8) needs this to ensure that newly uploaded packfiles are picked up as expected.


switch integers used for counting objects while indexing pack files to unsigned


provide a more useful error if the size of a packed object won't fit in 64 bits


let callers of got_pack_index() configure the rate limit of progress reporting


move pack indexing code into new file lib/pack_index.c Prepares for sharing code between got-index-pack and future gotd(8).


allow got_object_parse_tree to reuse entries buffer allocations for speed ok millert@


let callers of got_pack_create() configure rate-limiting of progress reporting Needed by future gotd(8), where progress reports will be sent to a network socket, rather than a local terminal.


do not crash if no delta cache is present while parsing deltas


move privsep code from pack_create.c into new file pack_create_privsep.c Needed by future gotd(8). ok op@


handle unlink(2) errors for mergepath, tmppath, and apath in apply_patch() ok op@


introduce got_path_move_file(); based on code from lib/patch.c ok op@


check for unlink(2) errors and don't try to unlink an already renamed file ok op@


check for unlink(2) errors in got_opentempfd() ok op@


check for unlink(2) errors with the == -1 idiom, rather than != 0 ok op@


move got_opentempfd() call out of got_pack_create() Future gotd(8) needs to run got_pack_create() in a chroot environment, so we can no longer open new temporary files inside got_pack_create(). ok op@