summaryrefslogtreecommitdiff
path: root/commit-graph.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2022-06-09 16:44:20 -0700
committerJunio C Hamano <gitster@pobox.com>2022-06-09 16:45:07 -0700
commit5a5ea141e7d5317cd049cb1e93b9127c1cec04bb (patch)
tree6da54ee57cbeacf4ee7efe51ec8dcdbe0792bc26 /commit-graph.c
parentdc8c8deaa6b5847733bd7df011a4c7b7d1a64e0a (diff)
revision: mark blobs needed for resolve-undo as reachable
The resolve-undo extension was added to the index in cfc5789a (resolve-undo: record resolved conflicts in a new index extension section, 2009-12-25). This extension records the blob object names and their modes of conflicted paths when the path gets resolved (e.g. with "git add"), to allow "undoing" the resolution with "checkout -m path". These blob objects should be guarded from garbage-collection while we have the resolve-undo information in the index (otherwise unresolve operation may try to use a blob object that has already been pruned away). But the code called from mark_reachable_objects() for the index forgets to do so. Teach add_index_objects_to_pending() helper to also add objects referred to by the resolve-undo extension. Also make matching changes to "fsck", which has code that is fairly similar to the reachability stuff, but have parallel implementations for all these stuff, which may (or may not) someday want to be unified. Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'commit-graph.c')
0 files changed, 0 insertions, 0 deletions