From: Junio C Hamano Date: Sat, 30 Aug 2008 05:31:51 GMT Subject: Re: [PATCH v4] Expand ~ and ~user in core.excludesfile, commit.template Message-ID: <7v8wuf2hmg.fsf@gitster.siamese.dyndns.org> In-Reply-To: Karl Chen writes: >>>>>> On 2008-08-29 12:28 PDT, Junio C Hamano writes: > > Junio> [3/3] Update the sole caller of user_path() to use > Junio> expand_user_path(). > > Actually I just looked closer at enter_repo() and it's not quite > as simple as your proposed patch, because enter_repo() wants to > concatenate suffixes like ".git". I thought the "just an illustration" patch at least took care of that part. The thing is that enter_repo() is not performance critical, it is where server side programs validate the repository path received from the other end of the network, and we can be stricter than necessary about path lengths. I do not particularly think it is necessary to convert it and use strbuf to allow arbitrarily long paths --- rejecting requests to an absurdly deep directory is not an end of the world there.