revision.c: remove implicit dependency on the_index
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
26d024ecf0
commit
2abf350385
@ -110,7 +110,7 @@ int add_files_to_cache(const char *prefix,
|
||||
memset(&data, 0, sizeof(data));
|
||||
data.flags = flags;
|
||||
|
||||
init_revisions(&rev, prefix);
|
||||
repo_init_revisions(the_repository, &rev, prefix);
|
||||
setup_revisions(0, NULL, &rev, NULL);
|
||||
if (pathspec)
|
||||
copy_pathspec(&rev.prune_data, pathspec);
|
||||
@ -232,7 +232,7 @@ static int edit_patch(int argc, const char **argv, const char *prefix)
|
||||
if (read_cache() < 0)
|
||||
die(_("Could not read the index"));
|
||||
|
||||
init_revisions(&rev, prefix);
|
||||
repo_init_revisions(the_repository, &rev, prefix);
|
||||
rev.diffopt.context = 7;
|
||||
|
||||
argc = setup_revisions(argc, argv, &rev, NULL);
|
||||
|
Reference in New Issue
Block a user