mirror of
https://github.com/libevent/libevent.git
synced 2025-01-31 09:12:55 +08:00
a8148cedcd
The old evhttp_decode_uri() function would act as tough it was doing an (illegal, undefined) decode operation on a whole URL at once, and treat + characters following a ? as different from + characters preceding one. But that's not useful: If you are decoding a URI before splitting off query parameters, you are begging to fail as soon as somebody gives you a value with an encoded & in it. The new evhttp_uridecode() function takes an argument that says whether to decode + signs. Both uridecode and uriencode also now support encoding or decoding to strings with internal 0-valued characters.