]> git.ipfire.org Git - thirdparty/git.git/commit - fast-import.c
fast-import: invalidate pack_id references after loosening
authorEric Wong <e@80x24.org>
Wed, 25 May 2016 22:54:02 +0000 (22:54 +0000)
committerJunio C Hamano <gitster@pobox.com>
Mon, 30 May 2016 00:58:34 +0000 (17:58 -0700)
commitd2986d0f290a065fb8a534fabfff36c40d37ae97
treeaa72980b793fbce0b54da1defdfe6c41acd28e1e
parentd9545c7f465ed103df44cd93caddfdd265757779
fast-import: invalidate pack_id references after loosening

When loosening a pack, the current pack_id gets reused when
checkpointing and the import does not terminate.  This causes
problems after checkpointing as the object table, branch, and
tag lists still contains pre-checkpoint references to the
recycled pack_id.

Merely clearing the object_table as suggested by Jeff King in
http://mid.gmane.org/20160517121330.GA7346@sigill.intra.peff.net
is insufficient as the marks set still contains references
to object entries.

Wrong pack_id references branch and tags lists do not cause
errors, but can lead to misleading crash reports and core dumps,
so they are also invalidated.

Signed-off-by: Eric Wong <e@80x24.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
fast-import.c
t/t9302-fast-import-unpack-limit.sh