summaryrefslogtreecommitdiff
path: root/update-ref.c
diff options
context:
space:
mode:
authorPetr Baudis <pasky@suse.cz>2005-11-10 20:55:13 +0100
committerJunio C Hamano <junkio@cox.net>2005-11-10 15:57:21 -0800
commitad7db62113368279a1b6994790bf30925fabea33 (patch)
tree1dc71999a7a4ddf2aee880b577fde6927a95248e /update-ref.c
parent14df4c41885ea19c9ce263111c6de994a4028601 (diff)
downloadgit-ad7db62113368279a1b6994790bf30925fabea33.tar.gz
Fix confusing git-update-ref error message
When git-update-ref has hit the "Ref %s changed to %s" error, I just stare at it, left puzzled. This patch attempts to reword that to a more useful and less confusing error message. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'update-ref.c')
-rw-r--r--update-ref.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/update-ref.c b/update-ref.c
index 65dc3d6385..d79dc52fd7 100644
--- a/update-ref.c
+++ b/update-ref.c
@@ -42,7 +42,7 @@ int main(int argc, char **argv)
if (oldval) {
if (memcmp(currsha1, oldsha1, 20))
- die("Ref %s changed to %s", refname, sha1_to_hex(currsha1));
+ die("Ref %s is at %s but expected %s", refname, sha1_to_hex(currsha1), sha1_to_hex(oldsha1));
/* Nothing to do? */
if (!memcmp(oldsha1, sha1, 20))
exit(0);