Browse Source
Free up the WANT_WRITE flag in ObjectToPack by switching the test to use the special offset value of 1. The Git pack file format calls for the first 4 bytes to be 'PACK', which means any object must start at an offset >= 4. Current versions require another 8 bytes in the header, placing the first object at offset = 12. So offset = 1 is an invalid location for an object, and can be used as a marker signal to indicate the writing loop has tried to write the object, but recursed into the base first. When an object is visited with offset == 1 it means there is a cycle in the delta base path, and the cycle must be broken. Change-Id: I2d05b9017c5f9bd9464b91d43e8d4b4a085e55bcstable-3.0
Shawn Pearce
12 years ago
1 changed files with 4 additions and 6 deletions
Loading…
Reference in new issue