diff options
author | Junio C Hamano <gitster@pobox.com> | 2023-08-24 19:32:33 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2023-08-24 19:32:33 +0300 |
commit | 84d79009d98d68aa811a210fa980c91e195c716f (patch) | |
tree | 04889c8a2697bc8a599c64d92423e83aa4537b49 /upload-pack.c | |
parent | 2f8aa2c3a0236c90a505364ddd4a463fd48bafbc (diff) | |
parent | 5f33a843de91f40ab2335e61d4373ace87301b07 (diff) |
Merge branch 'ds/upload-pack-error-sequence-fix'
Error message generation fix.
* ds/upload-pack-error-sequence-fix:
upload-pack: fix exit code when denying fetch of unreachable object ID
upload-pack: fix race condition in error messages
Diffstat (limited to 'upload-pack.c')
-rw-r--r-- | upload-pack.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/upload-pack.c b/upload-pack.c index 94751477ab..83f3d2651a 100644 --- a/upload-pack.c +++ b/upload-pack.c @@ -801,11 +801,12 @@ error: for (i = 0; i < data->want_obj.nr; i++) { struct object *o = data->want_obj.objects[i].item; if (!is_our_ref(o, data->allow_uor)) { + error("git upload-pack: not our ref %s", + oid_to_hex(&o->oid)); packet_writer_error(&data->writer, "upload-pack: not our ref %s", oid_to_hex(&o->oid)); - die("git upload-pack: not our ref %s", - oid_to_hex(&o->oid)); + exit(128); } } } |