diff options
author | Elijah Newren <newren@gmail.com> | 2010-07-31 14:11:46 -0600 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2010-08-02 15:31:59 -0700 |
commit | 9f9aa761305e909aca9a46ccb33a5872b36bcb8e (patch) | |
tree | 8b5732592d508f2a5b26242ff8a3f55b3a65ef34 /upload-pack.c | |
parent | b73f294150c0c134a954ab6772688a9a39b54896 (diff) | |
download | git-9f9aa761305e909aca9a46ccb33a5872b36bcb8e.tar.gz |
upload-pack: Improve error message when bad ref requested
When printing an error message saying a ref was requested that we do not
have, only print that ref, rather than the ref and everything sent to us
on the same packet line (e.g. protocol support specifications).
Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'upload-pack.c')
-rw-r--r-- | upload-pack.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/upload-pack.c b/upload-pack.c index 8f4c718bfe..fc79ddef25 100644 --- a/upload-pack.c +++ b/upload-pack.c @@ -549,7 +549,8 @@ static void receive_needs(void) */ o = lookup_object(sha1_buf); if (!o || !(o->flags & OUR_REF)) - die("git upload-pack: not our ref %s", line+5); + die("git upload-pack: not our ref %s", + sha1_to_hex(sha1_buf)); if (!(o->flags & WANTED)) { o->flags |= WANTED; add_object_array(o, NULL, &want_obj); |