From: Jeff King Date: Tue, 25 Oct 2016 00:30:23 GMT Subject: Re: [PATCH] hex: use unsigned index for ring buffer Message-ID: <20161025003023.6vaqofsixana3zno@sigill.intra.peff.net> In-Reply-To: On Mon, Oct 24, 2016 at 04:53:50PM -0700, Junio C Hamano wrote: > > So how about this? It gets rid of magic number 3 and works for array > > size that's not a power of two. And as a nice side effect it can't > > trigger a signed overflow anymore. > > Looks good to me. Peff? Any of the variants discussed in this thread is fine by me. -Peff