From: Junio C Hamano Date: Sat, 01 Mar 2008 20:25:34 GMT Subject: Re: [PATCH 2/4] make verify_one_pack() a bit less wrong wrt packed_git structure Message-ID: <7vwsomxkch.fsf@gitster.siamese.dyndns.org> In-Reply-To: Nicolas Pitre writes: >> I just quickly looked at verify_packfile() after applying your >> series, and it seems that nothing tries to access objects with >> only their SHA-1 names without explicitly telling which pack to >> read from, so it should still be safe even if we did not install >> the packed git (iow, the normal codepath would not try to pick >> up objects from the suspect pack that is being validated). >> >> But it made me feel a bit worried. > > The problem is with the patch that follows, which calls init_revindex(). Oh, Ok. I see nobody other than pack-check calls packed_object_info_detail, and that would be the only codepath that would load revindex in-core, so the change would be fine. I was worried about having to load revindex which would not help anything but info-detail which is pretty much useless for most operations.