mirror of
https://github.com/git-for-windows/git.git
synced 2026-04-20 17:54:13 -05:00
fsck: ensure full index
When verifying all blobs reachable from the index, ensure that a sparse index has been expanded to a full one to avoid missing some blobs. Signed-off-by: Derrick Stolee <dstolee@microsoft.com> Reviewed-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
48b3c7da6c
commit
2227ea175f
@@ -883,6 +883,8 @@ int cmd_fsck(int argc, const char **argv, const char *prefix)
|
||||
verify_index_checksum = 1;
|
||||
verify_ce_order = 1;
|
||||
read_cache();
|
||||
/* TODO: audit for interaction with sparse-index. */
|
||||
ensure_full_index(&the_index);
|
||||
for (i = 0; i < active_nr; i++) {
|
||||
unsigned int mode;
|
||||
struct blob *blob;
|
||||
|
||||
Reference in New Issue
Block a user