This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
application/x-www-form-urlencoded parser Item 6.5 says: "If use _charset_ flag is set, name is `_charset_`, and get an encoding for value, encoded, does not return failure, unset use _charset_ flag and set encoding override to the result of getting an encoding for value, encoded." It must say: "If use _charset_ flag is set, name is `_charset_`, and get an encoding for value, DECODED, does not return failure, unset use _charset_ flag and set encoding override to the result of getting an encoding for value, DECODED." How it works as I understand it: 1. We take 'value' part from name-value pair where name is "_charset_". It is byte sequence. 2. Then we decode this sequence (i.e. we convert it from byte sequence to code point sequence). 3. Then we try to get encoding by this string (method 'get an encding' from Encoding spec). If getting encoding not fails then we use these encoding to decode other name-value pairs.
https://github.com/whatwg/url/commit/f7ab990492ff6f6f69b557b7693149f42bba6bd8