diff options
author | Junio C Hamano <gitster@pobox.com> | 2017-02-27 13:57:18 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-02-27 13:57:18 -0800 |
commit | c13c783c9d3d7d3eff937b7bf3642d2a7fe32644 (patch) | |
tree | c650be76225f1b73aa5df51bcba519c532ebf437 /builtin/update-ref.c | |
parent | Merge branch 'jk/tempfile-ferror-fclose-confusion' (diff) | |
parent | branch: record creation of renamed branch in HEAD's log (diff) | |
download | tgif-c13c783c9d3d7d3eff937b7bf3642d2a7fe32644.tar.xz |
Merge branch 'km/delete-ref-reflog-message'
"git update-ref -d" and other operations to delete references did
not leave any entry in HEAD's reflog when the reference being
deleted was the current branch. This is not a problem in practice
because you do not want to delete the branch you are currently on,
but caused renaming of the current branch to something else not to
be logged in a useful way.
* km/delete-ref-reflog-message:
branch: record creation of renamed branch in HEAD's log
rename_ref: replace empty message in HEAD's log
update-ref: pass reflog message to delete_ref()
delete_ref: accept a reflog message argument
Diffstat (limited to 'builtin/update-ref.c')
-rw-r--r-- | builtin/update-ref.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/update-ref.c b/builtin/update-ref.c index 7f30d3a76f..0b2ecf41ae 100644 --- a/builtin/update-ref.c +++ b/builtin/update-ref.c @@ -433,7 +433,7 @@ int cmd_update_ref(int argc, const char **argv, const char *prefix) * For purposes of backwards compatibility, we treat * NULL_SHA1 as "don't care" here: */ - return delete_ref(refname, + return delete_ref(msg, refname, (oldval && !is_null_sha1(oldsha1)) ? oldsha1 : NULL, flags); else |