merge-recursive: ensure full index
Before iterating over all cache entries, ensure that a sparse index is expanded to a full index to avoid unexpected behavior. Signed-off-by: Derrick Stolee <dstolee@microsoft.com> Reviewed-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>maint
parent
3450a304aa
commit
f7ef64be0c
|
@ -522,6 +522,8 @@ static struct string_list *get_unmerged(struct index_state *istate)
|
|||
|
||||
unmerged->strdup_strings = 1;
|
||||
|
||||
/* TODO: audit for interaction with sparse-index. */
|
||||
ensure_full_index(istate);
|
||||
for (i = 0; i < istate->cache_nr; i++) {
|
||||
struct string_list_item *item;
|
||||
struct stage_data *e;
|
||||
|
|
Loading…
Reference in New Issue