kern/114578: [libc] wide character printing using swprintf(dst,
n, "%ls", txt) fails depending on LC_CTYPE
ache at FreeBSD.org
ache at FreeBSD.org
Sat Jul 14 17:58:04 UTC 2007
Synopsis: [libc] wide character printing using swprintf(dst, n, "%ls", txt) fails depending on LC_CTYPE
State-Changed-From-To: open->closed
State-Changed-By: ache
State-Changed-When: Sat Jul 14 17:48:21 UTC 2007
State-Changed-Why:
This code works as supposed by standards.
You may see errno comes from swprintf() (exactly - from wcrtomb())
and it is EILSEQ (Illegal byte sequence)
It is because "C" locale is 8bit wide so does not contain wide chars
outside 0 .. UCHAR_MAX range (and doesn't know how to convert them either),
so any attempt to convert them fails with EILSEQ.
http://www.freebsd.org/cgi/query-pr.cgi?pr=114578
More information about the freebsd-standards
mailing list