refs: add a transaction_commit() method

Signed-off-by: Ronnie Sahlberg <sahlberg@google.com>
Signed-off-by: David Turner <dturner@twopensource.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Ronnie Sahlberg
2016-09-04 18:08:16 +02:00
committed by Junio C Hamano
parent 49c0df6a68
commit 127b42a186
3 changed files with 20 additions and 4 deletions

9
refs.c
View File

@ -1377,3 +1377,12 @@ void assert_main_repository(struct ref_store *refs, const char *caller)
if (*refs->submodule)
die("BUG: %s called for a submodule", caller);
}
/* backend functions */
int ref_transaction_commit(struct ref_transaction *transaction,
struct strbuf *err)
{
struct ref_store *refs = get_ref_store(NULL);
return refs->be->transaction_commit(refs, transaction, err);
}