Re: [PATCH] Do not decode url protocol.

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Matthieu Moy
Date: Tuesday, June 22, 2010 - 4:34 am

Matthieu Moy <Matthieu.Moy@grenoble-inp.fr> writes:


Humm, looking a bit closer ...

Pascal Obry <pascal@obry.net> writes:


This function is called from multiple places :


char *url_decode(const char *url)
{
	return url_decode_internal(&url, NULL);
}

char *url_decode_parameter_name(const char **query)
{
	return url_decode_internal(query, "&=");
}

char *url_decode_parameter_value(const char **query)
{
	return url_decode_internal(query, "&");
}

I don't think you want to avoid escaping until the first slash in
url_decode_parameter_name and url_decode_parameter_value. I think you
want to patch url_decode, not url_decode_internal.


Are you sure the URL contains a / at this point? That would be a user
error if it doesn't, but has this been validated (with a clean error
message if needed) earlier in the code?

-- 
Matthieu Moy
http://www-verimag.imag.fr/~moy/
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] Do not decode url protocol., Pascal Obry, (Tue Jun 22, 2:25 am)
Re: [PATCH] Do not decode url protocol., Matthieu Moy, (Tue Jun 22, 4:22 am)
Re: [PATCH] Do not decode url protocol., Matthieu Moy, (Tue Jun 22, 4:34 am)
Re: [PATCH] Do not decode url protocol., Pascal Obry, (Tue Jun 22, 4:46 am)
Re: [PATCH] Do not decode url protocol., René Scharfe, (Wed Jun 23, 4:54 pm)
Re: [PATCH] Do not decode url protocol., Junio C Hamano, (Tue Jun 29, 9:50 am)