From: Linus Torvalds Date: Wed, 14 Sep 2005 21:15:18 GMT Subject: Re: [PATCH 0/4] Recovery after interrupted HTTP(s) fetch Message-ID: In-Reply-To: On Wed, 14 Sep 2005, Daniel Barkalow wrote: > > It's not about the refs at all. The issue is that, when it reaches a > commit that we already have, it assumes that we have everything that > commit references and stops there. It really ought to not do that, but I > think it might be too slow if it goes through everything all the time. No, you don't need to go through everything all the time. Do what the pack-sending stuff does: it assumes that it has everything that is reachable from the _old_ refs. It doesn't walk all the way to the root, it "just" walks far enough that it can ignore anything that was reachable from the old refs. Yes, it's slightly more complex than assuming "oh, I have this object, so I must have all of its ancestors", but it's a lot safer. Then the rule just becomes: only update refs once you've fetched all the objects. Linus