diff options
author | Nguyễn Thái Ngọc Duy <pclouds@gmail.com> | 2018-08-13 19:14:39 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-08-14 00:14:44 +0300 |
commit | 82ea77eca7af238f1ee65f5cbc945a01e16ee97a (patch) | |
tree | b22a81980f6a20a4e9148233f124f5d6bb5c4270 /builtin/am.c | |
parent | 332a82a52222da253cd5023cd4c5cde2d51636b9 (diff) |
apply.c: make init_apply_state() take a struct repository
We're moving away from the_index in this code. "struct index_state *"
could be added to struct apply_state. But let's aim long term and put
struct repository here instead so that we could even avoid more global
states in the future. The index will be available via
apply_state->repo->index.
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/am.c')
-rw-r--r-- | builtin/am.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/am.c b/builtin/am.c index 2c19e69f58..9f7ecf6ecb 100644 --- a/builtin/am.c +++ b/builtin/am.c @@ -1464,7 +1464,7 @@ static int run_apply(const struct am_state *state, const char *index_file) int force_apply = 0; int options = 0; - if (init_apply_state(&apply_state, NULL)) + if (init_apply_state(&apply_state, the_repository, NULL)) BUG("init_apply_state() failed"); argv_array_push(&apply_opts, "apply"); |