... and an --amend: --- reflog-walk.c | 6 ++++-- 1 files changed, 4 insertions(+), 2 deletions(-) diff --git a/reflog-walk.c b/reflog-walk.c index 658cba9..d4b49c7 100644 --- a/reflog-walk.c +++ b/reflog-walk.c @@ -203,14 +203,16 @@ void fake_reflog_parent(struct reflog_walk_info *info, struct commit *commit) reflog = &commit_reflog->reflogs->items[commit_reflog->recno]; info->last_commit_reflog = commit_reflog; + commit_reflog->recno--; commit_info->commit = (struct commit *)parse_object(reflog->osha1); - if (!commit_info->commit) + if (!commit_info->commit) { + commit->parents = NULL; return; + } commit->parents = xcalloc(sizeof(struct commit_list), 1); commit->parents->item = commit_info->commit; commit->object.flags &= ~(ADDED | SEEN | SHOWN); - commit_reflog->recno--; } void show_reflog_message(struct reflog_walk_info* info) - To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html