Merge branch 'jk/unused-parameter-cleanup'
[gitweb.git] / apply.c
diff --git a/apply.c b/apply.c
index ccab7e7907c874ea1bd6c65fb933abaffc5d0001..beed3091d2a347116a11cb4b593a70b2c90406f8 100644 (file)
--- a/apply.c
+++ b/apply.c
@@ -4019,7 +4019,7 @@ static int read_apply_cache(struct apply_state *state)
                return read_index_from(state->repo->index, state->index_file,
                                       get_git_dir());
        else
-               return read_index(state->repo->index);
+               return repo_read_index(state->repo);
 }
 
 /* This function tries to read the object name from the current index */
@@ -4712,7 +4712,8 @@ static int apply_patch(struct apply_state *state,
                                                  state->index_file,
                                                  LOCK_DIE_ON_ERROR);
                else
-                       hold_locked_index(&state->lock_file, LOCK_DIE_ON_ERROR);
+                       repo_hold_locked_index(state->repo, &state->lock_file,
+                                              LOCK_DIE_ON_ERROR);
        }
 
        if (state->check_index && read_apply_cache(state) < 0) {