Re: Java Inflater problem decompressing packfile
- From
Jeff King <peff@peff.net>
- Date
- Apr 17, 2011, 04:36 UTC
- Message-ID
- <20110417043607.GA10831@sigill.intra.peff.net>
- In-Reply-To
- <1302963832717-6279028.post@n2.nabble.com>
On Sat, Apr 16, 2011 at 07:23:52AM -0700, madmarcos wrote:
> No, my inflater doesn't handle deltas, yet. > But there are a few reasons why I don't think that's the case. > 1. The project has only been pushed once to the git repository before my > tests. No updates to the git repository project or anything like that.
You can still have deltas between blobs in a single commit, but only if you have similar blobs.
> 2. If it were a delta, would the first 1/3 of it be completely normal and > readable? There is no pattern that I can see to the remaining 2/3. It looks > as if the characters in the 2/3 part were interleaved with the other > characters about 10 times.
It wouldn't be completely normal, but you might see chunks of the file along with binary patch instructions (like "put this chunk at offset ...").
> 3. The object type in the header is parsed as 3, or a blob. Aren't the delta > object types higher numbers than that?
Yeah, if it is coming up as type 3, then it should definitely be a whole, literal blob.
As far as your Java code, I don't see anything overtly wrong, but then, I know absolutely nothing about any of the classes you are using.
-Peff