summaryrefslogtreecommitdiff
path: root/builtin/am.c
diff options
context:
space:
mode:
Diffstat (limited to 'builtin/am.c')
-rw-r--r--builtin/am.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/builtin/am.c b/builtin/am.c
index 72e928c..b6eeb46 100644
--- a/builtin/am.c
+++ b/builtin/am.c
@@ -1633,7 +1633,8 @@ static void do_commit(const struct am_state *state)
if (!get_oid_commit("HEAD", &parent)) {
old_oid = &parent;
- commit_list_insert(lookup_commit(&parent), &parents);
+ commit_list_insert(lookup_commit(the_repository, &parent),
+ &parents);
} else {
old_oid = NULL;
say(state, stderr, _("applying to an empty history"));