libutf8 provides a C API for encoding and decoding
UTF-8. It uses the C type wchar_t as its internal
character representation. libutf8 is a "safe" decoder
— it will not accept overlong byte sequences.
You can download the latest version by cloning the git repository:
git clone git://git.lwithers.me.uk/libutf8
| Version | Date | Source | GPG Signature (key) | Documentation | Doc Signature | Dependencies |
|---|---|---|---|---|---|---|
| 1.3.2 | 2009-11-03 | .tar.bz2 | .tar.bz2.asc | .tar.bz2 | .tar.bz2.asc |
Older releases may be found here.
utf8_encoder(), where passing a NULL pointer
would result in the pointer being dereferenced rather than an EINVAL error
returned.utf8_decode_char2(): test for overlength character
was wrong.utf8_decode_char2(): return value was not correctly
set to (wchar_t)-1 on error.utf8_decode_char() and the
*_force() variants.utf8_isvalid() function into several new variants
to test for valid UCS-4, UTF-32 and UTF-16 codepoints.utf8_iseol() to test for end-of-line characters.bool type to just use plain C
int instead.