Re: Git Community Book
- From
Linus Torvalds <torvalds@linux-foundation.org>
- Date
- Sep 5, 2008, 20:27 UTC
- Message-ID
- <alpine.LFD.1.10.0809051317510.3117@nehalem.linux-foundation.org>
- In-Reply-To
- <d411cc4a0809051208k2a15c4a7te09a6979929e52f7@mail.gmail.com>
On Fri, 5 Sep 2008, Scott Chacon wrote:
> > http://book.git-scm.com/7_the_packfile.html
The checksums in the index file "trailers" are all claiming to be 4 bytes, and that's wrong - they're full SHA1 sums at 20 bytes each.
The v2 pack-file _also_ has per-object CRC's, and those are indeed just 4 bytes each, and are correctly listed as such.
The pack-file itself also has a few more things there, it's not just the "PACK" string and then the objects. It has two more 32-bit words: a pack file version number and the number of entries in the pack-file (all network byte order). It also has its own checksum at the end (20-byte SHA1 again).
But looks good otherwise from a quick look.
Linus