mirror of
https://github.com/libgit2/libgit2.git
synced 2026-06-22 06:26:26 +00:00
examples: fix remaining review comments
This commit is contained in:
@@ -244,6 +244,7 @@ static int create_merge_commit(git_repository *repo, git_index *index, merge_opt
|
||||
check_lg2(git_repository_head(&head_ref, repo), "failed to get repo HEAD", NULL);
|
||||
if (resolve_refish(&merge_commit, repo, opts->heads[0])) {
|
||||
fprintf(stderr, "failed to resolve refish %s", opts->heads[0]);
|
||||
return -1;
|
||||
}
|
||||
|
||||
/* Maybe that's a ref, so DWIM it */
|
||||
@@ -293,6 +294,7 @@ static int create_merge_commit(git_repository *repo, git_index *index, merge_opt
|
||||
git_repository_state_cleanup(repo);
|
||||
|
||||
cleanup:
|
||||
free(parents);
|
||||
return err;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user