[PATCH] Fix UTF-16 surrogate handling in __utf8_mbtowc
Corinna Vinschen
vinschen@redhat.com
Tue Jul 28 18:56:00 GMT 2009
On Jul 28 18:57, Corinna Vinschen wrote:
> The downside of this implementation is that an application could be
> happy with the result after only having read the first three bytes
> of the four byte sequence from the input string and just stop. This
> results in an incomplete surrogate pair. However, as far as I can see
> it's rather unlikely, and it's still better that not handling Unicode
> values outside the base plane at all.
Oh, btw, the same could of course already happen with the old
implementation, so that's not a regression.
Corinna
--
Corinna Vinschen
Cygwin Project Co-Leader
Red Hat
More information about the Newlib
mailing list