From: H. Peter Anvin Date: Thu, 28 Aug 2008 04:58:05 GMT Subject: Re: Git-aware HTTP transport Message-ID: <48B6305D.1080004@zytor.com> In-Reply-To: <20080828044205.GB10238@spearce.org> Shawn O. Pearce wrote: > >> Just an implementation detail for the server, however: for an *empty* >> repository (one which has no refs at all), the server needs to *not* >> transmit the redirect, or there will be a loop :) It is unnecessary, >> anyway, since there is inherently nothing to do. > > Actually that's not true. A correct client won't loop. > > An empty repository is required to send "refs" section header. > So the client will see the "refs" header and know that the complete > set of refs is following. Only nothing follows, so it knows the > complete set is the empty set. > > A redirect with no ref data won't have the "refs" section header. > So the client knows that it cannot conclude anything from that > exchange and must follow the redirect. > Ah, good point. -hpa