[PATCH] hgweb: specify a charset when sending raw text files
Julian Cowley
julian at lava.net
Thu Jun 10 06:00:54 CDT 2010
On Thu, 10 Jun 2010, timeless wrote:
> so, personally, i prefer not sending an encoding if people don't
> *really* know what it is.
>
> browsers are allowed to sniff if there isn't an encoding specified,
> but if you lie and give it one, browsers aren't supposed to sniff.
That's what I thought at first, too. However, a closer reading of the
HTTP 1.1 spec says that a missing charset parameter has a default of
ISO-8859-1. See RFC 2616 sections 3.4.1 [1] and 3.7.1 [2].
In light of this, I agree with Matt that we should always be sending a
charset parameter.
[1] http://tools.ietf.org/html/rfc2616#section-3.4.1
[2] http://tools.ietf.org/html/rfc2616#section-3.7.1
More information about the Mercurial-devel
mailing list