builtin: stop using the_index
Convert builtins to use `the_repository->index` instead of `the_index`. Signed-off-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
319ba14407
commit
f59aa5e0a9
@ -1,4 +1,3 @@
|
||||
#define USE_THE_INDEX_VARIABLE
|
||||
#include "builtin.h"
|
||||
#include "config.h"
|
||||
#include "diff.h"
|
||||
@ -206,7 +205,7 @@ int cmd_diff_tree(int argc, const char **argv, const char *prefix)
|
||||
opt->diffopt.rotate_to_strict = 0;
|
||||
opt->diffopt.no_free = 1;
|
||||
if (opt->diffopt.detect_rename) {
|
||||
if (!the_index.cache)
|
||||
if (the_repository->index->cache)
|
||||
repo_read_index(the_repository);
|
||||
opt->diffopt.setup |= DIFF_SETUP_USE_SIZE_CACHE;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user