Anders Kaseorg dixit:
>On Sun, 5 Jan 2014, Thorsten Glaser wrote:
>> The correct fix here is to prevent p5-CGI from adding any charset
>> if none was already given (e.g. via guess_mimetype).
>
>That will not help you, because HTTP also specifies the default charset 
>for text/* as ISO-8859-1 if not given explicitly 
>(https://tools.ietf.org/html/rfc2616#section-3.7.1).  

In real life, it does help: if none is specified, various user agents
may (and do¹) guess. This occasionally helps.

>If you know your content is UTF-8, you should set
>
>$default_text_plain_charset = 'utf-8';
>
>in gitweb.conf.

We can try that, but it doesn’t change my opinion that gitweb
should not add a charset if none was already given. Alone for
the fact that the presence of an explicit charset attribute
says “I, the sender, am 100% sure that this is the correct
charset, so use it!”, which gitweb just cannot be, ever, as
git does not store the charset.

I don’t want to play bts control pingpong with you, but please
consider this patch nevertheless, and feed it upstream.

bye,
//mirabilos

① and do: unfortunately, Mozilla derivates always default to
  latin1 for many UTF-8 files…
-- 
Stéphane, I actually don’t block Googlemail, they’re just too utterly
stupid to successfully deliver to me (or anyone else using Greylisting
and not whitelisting their ranges). Same for a few other providers such
as Hotmail. Some spammers (Yahoo) I do block.

Reply via email to