Re: [PATCH] read-cache: avoid misaligned reads in index v4
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Sep 26, 2022, 23:02 UTC
- Message-ID
- <xmqqmtalagdi.fsf@gitster.g>
- In-Reply-To
- <YzH+IPFBGleIsAUe@coredump.intra.peff.net>
Jeff King <peff@peff.net> writes:
> I do find it a bit more straight-forward, but the extra copy is ugly, > plus the "yuck" comment.
Yeah, the "yuck" memcpy() is, eh, unfortunate. Consistently using a single "pointer" (pos) to keep track of where we are does make the structure of the code appear uniform and easier to follow, though.