summaryrefslogtreecommitdiff
path: root/builtin/tag.c
diff options
context:
space:
mode:
authorRonnie Sahlberg <sahlberg@google.com>2014-04-30 19:22:42 (GMT)
committerJunio C Hamano <gitster@pobox.com>2014-10-15 17:47:22 (GMT)
commitdb7516ab9f435e3ce86b257c6631fb4d2dfb12ae (patch)
tree84b452b76a6315511691d30f7e97a2a9388b25c1 /builtin/tag.c
parentdbdcac7d5c5eea314ec4c318a5e88cff427e9f0e (diff)
downloadgit-db7516ab9f435e3ce86b257c6631fb4d2dfb12ae.zip
git-db7516ab9f435e3ce86b257c6631fb4d2dfb12ae.tar.gz
git-db7516ab9f435e3ce86b257c6631fb4d2dfb12ae.tar.bz2
refs.c: pass the ref log message to _create/delete/update instead of _commit
Change the ref transaction API so that we pass the reflog message to the create/delete/update functions instead of to ref_transaction_commit. This allows different reflog messages for each ref update in a multi-ref transaction. Signed-off-by: Ronnie Sahlberg <sahlberg@google.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/tag.c')
-rw-r--r--builtin/tag.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/builtin/tag.c b/builtin/tag.c
index a81b9e4..e633f4e 100644
--- a/builtin/tag.c
+++ b/builtin/tag.c
@@ -733,8 +733,8 @@ int cmd_tag(int argc, const char **argv, const char *prefix)
transaction = ref_transaction_begin(&err);
if (!transaction ||
ref_transaction_update(transaction, ref.buf, object, prev,
- 0, 1, &err) ||
- ref_transaction_commit(transaction, NULL, &err))
+ 0, 1, NULL, &err) ||
+ ref_transaction_commit(transaction, &err))
die("%s", err.buf);
ref_transaction_free(transaction);
if (force && !is_null_sha1(prev) && hashcmp(prev, object))