Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 18 May 2016 18:07:47 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-bugs@FreeBSD.org
Subject:   [Bug 209617] wctomb() is completely broken when UTF-8 locales are used
Message-ID:  <bug-209617-8@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D209617

            Bug ID: 209617
           Summary: wctomb() is completely broken when UTF-8 locales are
                    used
           Product: Base System
           Version: 10.3-RELEASE
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: bin
          Assignee: freebsd-bugs@FreeBSD.org
          Reporter: jau@iki.fi

For any and all unicode code points larger than 0xff wctomb() returns -1
and sets errno to EILSEQ when LC_CTYPE is set to a UTF-8 locale.

Another symptom of something going wrong is that the proper UTF-8 encoding
for code point 0xff would be two bytes 11000011 10111111, but wctomb() just
passes it through as one byte 11111111 with no conversion.

I noticed this on FreeBSD 10.3-STABLE r299892 on amd64.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-209617-8>