[whatwg] UTF-16 encoding default

L. David Baron dbaron at dbaron.org
Fri Jul 17 09:13:51 PDT 2009


On Wednesday 2009-07-15 04:24 +0000, Ian Hickson wrote:
> Firefox checks to see if the first two bytes are null/not-null or 
> not-null/null and acts accordingly; if they're both not null it uses BE 
> and if they're both null it does something I don't recognise (and checks 
> both the UTF-8 and UTF-16 character encodings in the menu...).

That's odd.  For what it's worth, the code (the last function in a
file incorrectly named nsUCS2BEToUnicode.cpp) looks like it should
use BE in any case where there was no BOM and we didn't hit the case
where exactly one of the two first bytes was non-null.

(You didn't have any autodetection enabled, did you?)

-David

-- 
L. David Baron                                 http://dbaron.org/
Mozilla Corporation                       http://www.mozilla.com/



More information about the whatwg mailing list