From 3d20c636af05c44a6ff4df9309c2bca108ee149b Mon Sep 17 00:00:00 2001 From: "Shawn O. Pearce" Date: Tue, 10 Feb 2009 13:36:12 -0800 Subject: Clear the delta base cache during fast-import checkpoint Otherwise we may reuse the same memory address for a totally different "struct packed_git", and a previously cached object from the prior occupant might be returned when trying to unpack an object from the new pack. Found-by: Daniel Barkalow Signed-off-by: Shawn O. Pearce Signed-off-by: Junio C Hamano --- fast-import.c | 1 + 1 file changed, 1 insertion(+) (limited to 'fast-import.c') diff --git a/fast-import.c b/fast-import.c index 6d5ee6f463..5bc9ce2cc9 100644 --- a/fast-import.c +++ b/fast-import.c @@ -943,6 +943,7 @@ static void end_packfile(void) { struct packed_git *old_p = pack_data, *new_p; + clear_delta_base_cache(); if (object_count) { char *idx_name; int i; -- cgit v1.2.1