From e5994eb02d1f43dd5f9104854fb6fb7448264167 Mon Sep 17 00:00:00 2001 From: Arthur Schreiber Date: Thu, 2 Jan 2014 16:56:09 +0100 Subject: [PATCH 1/2] Add missing `git_reference_symbolic_create_with_log`. It's exported in the headers, but the implementation was missing. --- src/refs.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/refs.c b/src/refs.c index 83343f41b..f60ac3122 100644 --- a/src/refs.c +++ b/src/refs.c @@ -444,6 +444,21 @@ int git_reference_symbolic_create( return reference__create(ref_out, repo, name, NULL, target, force, NULL, NULL); } +int git_reference_symbolic_create_with_log( + git_reference **ref_out, + git_repository *repo, + const char *name, + const char *target, + int force, + const git_signature *signature, + const char *log_message) +{ + assert(target && signature && log_message); + + return reference__create( + ref_out, repo, name, NULL, target, force, signature, log_message); +} + static int ensure_is_an_updatable_direct_reference(git_reference *ref) { if (ref->type == GIT_REF_OID) From 0b7951788cb793cea45594b168e3936527a3277a Mon Sep 17 00:00:00 2001 From: Arthur Schreiber Date: Thu, 2 Jan 2014 16:58:13 +0100 Subject: [PATCH 2/2] Allow the log message to be NULL. --- src/refs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/refs.c b/src/refs.c index f60ac3122..c8a833b6b 100644 --- a/src/refs.c +++ b/src/refs.c @@ -427,7 +427,7 @@ int git_reference_create_with_log( const git_signature *signature, const char *log_message) { - assert(oid && signature && log_message); + assert(oid && signature); return reference__create( ref_out, repo, name, oid, NULL, force, signature, log_message); @@ -453,7 +453,7 @@ int git_reference_symbolic_create_with_log( const git_signature *signature, const char *log_message) { - assert(target && signature && log_message); + assert(target && signature); return reference__create( ref_out, repo, name, NULL, target, force, signature, log_message);