Re: [PATCH v2 0/25] prune-safety
- From
Jeff King <peff@peff.net>
- Date
- Oct 17, 2014, 04:49 UTC
- Message-ID
- <20141017044910.GA12624@peff.net>
- In-Reply-To
- <CAPc5daX0AFv9jDrFyd_OnupW5AfZW9Je_rgzaViX_xxs3SG5zg@mail.gmail.com>
On Thu, Oct 16, 2014 at 09:13:39PM -0700, Junio C Hamano wrote:
> Just being curious, but would the same bug, if allowed to be triggered > cutting repacking of your repository, have corrupted the resulting bitmap?
I didn't test, but yes, almost certainly. The bug was in list-objects.c, which is used by pack-objects to generate the list of objects to pack, as well as to build the bitmaps. So not only would it have corrupted the bitmaps, a `git repack -ad`[1] would have dropped the object completely, corrupting the repository!
-Peff
[1] git-gc uses `repack -Ad`, of course. So assuming you had packed more
recently than 2 weeks ago, it would have just been ejected to a
loose object. Small comfort. :)-Peff