read-cache.c: kill read_index()
read_index() shares the same problem as hold_locked_index(): it assumes $GIT_DIR/index. Move all call sites to repo_read_index() instead. read_index_preload() and read_index_unmerged() are also killed as a consequence. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
fb4a8464a6
commit
e1ff0a32e4
@ -3576,7 +3576,7 @@ int merge_recursive(struct merge_options *o,
|
||||
|
||||
discard_cache();
|
||||
if (!o->call_depth)
|
||||
read_cache();
|
||||
repo_read_index(the_repository);
|
||||
|
||||
o->ancestor = "merged common ancestors";
|
||||
clean = merge_trees(o, get_commit_tree(h1), get_commit_tree(h2),
|
||||
|
||||
Reference in New Issue
Block a user