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

Re: [PATCH 1/3] make index-pâck able to complete thin packs

From
Nicolas Pitre <nico@cam.org>
Date
Oct 28, 2006, 00:41 UTC
Message-ID
<Pine.LNX.4.64.0610272032110.11384@xanadu.home>
In-Reply-To
<7vmz7hcs0o.fsf@assigned-by-dhcp.cox.net>
On Fri, 27 Oct 2006, Junio C Hamano wrote:
> Nicolas Pitre <nico@cam.org> writes:
> 
> > +static void fix_unresolved_deltas(int nr_unresolved)
> > +{
[...]
Show 8 quoted lines
> > +		if (objects[d->obj_no].real_type != OBJ_REF_DELTA)
> > +			continue;
> 
> Just for the sake of my own sanity checking,...
> 
> Is it because base objects of OFS_DELTA _must_ exist in the same
> pack (even when --thin) that we do not have to worry about them
> in this function?

Indeed. Otherwise it would be impossible to determine the offset to the base object if that base object is not in the pack.

That doesn't mean there isn't any OFS_DELTA left to resolve though. But this function is only about adding missing objects to the pack and the deltas that need them must be REF_DELTA objects.

Once a REF_DELTA has been resolved with an external object, it then constitute a possible new base for remaining OFS_DELTA or REF_DELTA objects, and that is found recursively in resolve_delta().

Previous: Junio C Hamano
Message 15 of 15 in “make index-pâck able to complete thin packs”
  1. 1/3 make index-pâck able to complete thin packsNicolas Pitre, Oct 26, 2006
  2. Junio C HamanoOct 26, 2006
  3. Jakub NarebskiOct 26, 2006
  4. Karl HasselströmOct 26, 2006
  5. Junio C HamanoOct 26, 2006
  6. Karl HasselströmOct 26, 2006
  7. Jakub NarebskiOct 26, 2006
  8. Nicolas PitreOct 26, 2006
  9. Catalin MarinasOct 26, 2006
  10. Karl HasselströmOct 26, 2006
  11. Catalin MarinasOct 26, 2006
  12. Catalin MarinasOct 26, 2006
  13. stg mailKarl Hasselström, Oct 26, 2006
  14. Junio C HamanoOct 27, 2006
  15. Nicolas PitreOct 28, 2006

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.