[xml] French character encoding problem

We are using libxml version 2.0.0 on Red Hat Linux Enterprise version 2.4.9.
I have an xml file with the first line specifying the encoding scheme :
         <?xml version="1.0" encoding="LATIN1" ?>
and one of the text node in the file is the following :
After the document has been parsed via xmlParseFile( ) and xmlDocGetRootElement( ), a call to xmlNodeGetContent( ) returns "FRANÃîOIS" (a strlen of 9) instead of "FRANÃOIS".
I put in a call to xmlDebugDumpDocument( ) and it shows "FRAN#C3#87OIS".
On the other hand, if I run xmllint from the command line to check the file, "FRANÃOIS" was properly returned and displayed.
Am I missing something in the C program to convert the encoded sequence to the origianl character ?

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]