summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--builtin/log.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/builtin/log.c b/builtin/log.c
index cf303b2c06..630d6cff2f 100644
--- a/builtin/log.c
+++ b/builtin/log.c
@@ -377,9 +377,9 @@ static int cmd_log_walk(struct rev_info *rev)
* walking the reflogs.
*/
free_commit_buffer(commit);
+ free_commit_list(commit->parents);
+ commit->parents = NULL;
}
- free_commit_list(commit->parents);
- commit->parents = NULL;
if (saved_nrl < rev->diffopt.needed_rename_limit)
saved_nrl = rev->diffopt.needed_rename_limit;
if (rev->diffopt.degraded_cc_to_c)