git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 2/3] implement some resilience against pack corruptions

From
Junio C Hamano <gitster@pobox.com>
Date
Jun 24, 2008, 04:49 UTC
Message-ID
<7vhcbje8ss.fsf@gitster.siamese.dyndns.org>
In-Reply-To
<alpine.LFD.1.10.0806232122180.2979@xanadu.home>
Nicolas Pitre <nico@cam.org> writes:
Show 5 quoted lines
> We should be able to fall back to loose objects or alternative packs when
> a pack becomes corrupted.  This is especially true when an object exists
> in one pack only as a delta but its base object is corrupted.  Currently
> there is no way to retrieve the former object even if the later is
> available in another pack or loose.
All three patches applied, but with the following squashed in.  Thanks
 sha1_file.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/sha1_file.c b/sha1_file.c
index a5cef94..9330bc4 100644
--- a/sha1_file.c
+++ b/sha1_file.c
@@ -1418,8 +1418,8 @@ const char *packed_object_info_detail(struct packed_git *p,
 		case OBJ_OFS_DELTA:
 			obj_offset = get_delta_base(p, &w_curs, &curpos, type, obj_offset);
 			if (!obj_offset)
-				die("pack %s contains bad delta base reference",
-				    p->pack_name, type);
+				die("pack %s contains bad delta base reference of type %s",
+				    p->pack_name, typename(type));
 			if (*delta_chain_length == 0) {
 				revidx = find_pack_revindex(p, obj_offset);
 				hashcpy(base_sha1, nth_packed_object_sha1(p, revidx->nr));
Previous: Nicolas Pitre
Message 4 of 4 in “implement some resilience against pack corruptions”
  1. 2/3 implement some resilience against pack corruptionsNicolas Pitre, Jun 24, 2008
  2. Shawn O. PearceJun 24, 2008
  3. Nicolas PitreJun 24, 2008
  4. Junio C HamanoJun 24, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.