Update of bug #17373 (project freeciv):
Category: None => general
Status: None => Ready For Test
_______________________________________________________
Follow-up Comment #6:
> (which is looking for Unicode Byte Order Marks, for no reason I
> understand)
Well, it's not prepared for any extra bytes, such as BOM. It assumes that each
int represent one character when it counts them. It rather asserts than tries
to adjust when there's BOM. This assert is *not* for something that is assumed
never to happen, but for something we don't bother to handle! Encoding
conversion is free to add BOM if it wants, and from this bug report it seems
obvious that at least on one platform it does.
Attached untested patch should make it handle BOM correctly (just skip wihtout
counting)
> I think it assumes that sizeof(int)==4*sizeof(char)
As it converts to "UCS-4", it assumes that sizeof(int) == 32 bits. I didn't do
anything to this yet.
(file #15461)
_______________________________________________________
Additional Item Attachment:
File name: BOM.diff Size:0 KB
_______________________________________________________
Reply to this item at:
<http://gna.org/bugs/?17373>
_______________________________________________
Message sent via/by Gna!
http://gna.org/
_______________________________________________
Freeciv-dev mailing list
[email protected]
https://mail.gna.org/listinfo/freeciv-dev