]> git.ipfire.org Git - thirdparty/git.git/blobdiff - upload-pack.c
upload-pack: Improve error message when bad ref requested
[thirdparty/git.git] / upload-pack.c
index 8f4c718bfee4d682cf22e8134315aaa84aba171f..fc79ddef255a49176acab52c6492c1086b4e6e44 100644 (file)
@@ -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);