From b4b79ac3dbca9088539a10d8d65bfc06504c3c2e Mon Sep 17 00:00:00 2001 From: schu Date: Wed, 15 Feb 2012 00:12:53 +0100 Subject: commit: actually allow yet to be born update_ref git_commit_create is supposed to update the given reference "update_ref", but segfaulted in case of a yet to be born reference. Fix it. Signed-off-by: schu --- include/git2/commit.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'include/git2/commit.h') diff --git a/include/git2/commit.h b/include/git2/commit.h index 6d8cf53af..c274b6b95 100644 --- a/include/git2/commit.h +++ b/include/git2/commit.h @@ -191,7 +191,8 @@ GIT_EXTERN(const git_oid *) git_commit_parent_oid(git_commit *commit, unsigned i * will be updated to point to this commit. If the reference * is not direct, it will be resolved to a direct reference. * Use "HEAD" to update the HEAD of the current branch and - * make it point to this commit + * make it point to this commit. If the reference doesn't + * exist yet, it will be created. * * @param author Signature representing the author and the authory * time of this commit -- cgit v1.2.1