Re: [PATCH v2] credential: fix matching URLs with multiple levels in path
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Apr 24, 2020, 20:20 UTC
- Message-ID
- <xmqqeescd4a2.fsf@gitster.c.googlers.com>
- In-Reply-To
- <20200424045030.GA44448@Carlos-MBP>
Carlo Marcelo Arenas Belón <carenas@gmail.com> writes:
Show 18 quoted lines
> On Wed, Apr 22, 2020 at 07:51:09PM +0000, brian m. carlson wrote: >> --- a/strbuf.h >> +++ b/strbuf.h >> @@ -378,11 +378,15 @@ size_t strbuf_expand_dict_cb(struct strbuf *sb, >> */ >> void strbuf_addbuf_percentquote(struct strbuf *dst, const struct strbuf *src); >> >> +#define STRBUF_PERCENTENCODE_PATH 1 >> + >> /** >> * Append the contents of a string to a strbuf, percent-encoding any characters >> * that are needed to be encoded for a URL. >> + * >> + * If STRBUF_PERCENTENCODE_PATH is set in flags, don't percent-encode slashes. >> */ > > wouldn't it be better to call this STRBUF_PERCENTENCODE_SLASH instead?, since > it is actually not applied to path?
I was about to say the same thing. Can we phrase it a bit shorter than PERCENTENCODE, by the way?