Does anyone have some sample code showing the use of "apr_xlate_conv_buffer(
)" converting between UTF-8 and UTF-16?  I've looked through
"apr-util/test/testxlate.c", but it doesn't seem to cover any multi-byte
conversions:

# /* 1. Identity transformation: UTF-8 -> UTF-8 */
# retcode |= one_test("UTF-8", "UTF-8", test_utf8, test_utf8, pool);
#
# /* 2. UTF-8 <-> ISO-8859-1 */
# retcode |= one_test("UTF-8", "ISO-8859-1", test_utf8, test_latin1, pool);
# retcode |= one_test("ISO-8859-1", "UTF-8", test_latin1, test_utf8, pool);
#
# /* 3. ISO-8859-1 <-> ISO-8859-2, identity */
# retcode |= one_test("ISO-8859-1", "ISO-8859-2",
#                     test_latin1, test_latin2, pool);
# retcode |= one_test("ISO-8859-2", "ISO-8859-1",
#                     test_latin2, test_latin1, pool);
#
# /* 4. Transformation using charset aliases */
# retcode |= one_test("UTF-8", "UTF-7", test_utf8, test_utf7, pool);
# retcode |= one_test("UTF-7", "UTF-8", test_utf7, test_utf8, pool);

Are there any tests using UTF-16?  Can anyone confirm that this works?

-david

Reply via email to