I've tracked down a bug between two pieces of software, one of them is emitting the header
Content-Type: application/x-bittorrent; charset=utf-8
And the other is handling this incorrectly, but handles it correctly if the charset parameter is dropped. I need to know which software to write a patch for!
According to the W3C's website:
Documents transmitted with HTTP that are of type text, such as text/html, text/plain, etc., can send a charset parameter in the HTTP header to specify the character encoding of the document.
Which implies that documents not of type text should not send this header, I think. However, RFC 2068 states:
The "charset" parameter is used with some media types to define the character set (section 3.4) of the data
I cannot find anywhere in the spec that it is incorrect to add a charset parameter to media types other than text, so my question is: Is the software emitting this header incorrect, or the software consuming it?