Merge branch 'jk/robustify-parse-commit'
* jk/robustify-parse-commit: checkout: do not die when leaving broken detached HEAD use parse_commit_or_die instead of custom message use parse_commit_or_die instead of segfaulting assume parse_commit checks for NULL commit assume parse_commit checks commit->object.parsed log_tree_diff: die when we fail to parse a commit
This commit is contained in:
@ -90,8 +90,7 @@ struct commit_list *get_shallow_commits(struct object_array *heads, int depth,
|
||||
cur_depth = *(int *)commit->util;
|
||||
}
|
||||
}
|
||||
if (parse_commit(commit))
|
||||
die("invalid commit");
|
||||
parse_commit_or_die(commit);
|
||||
cur_depth++;
|
||||
if (cur_depth >= depth) {
|
||||
commit_list_insert(commit, &result);
|
||||
|
Reference in New Issue
Block a user