[ http://issues.apache.org/jira/browse/XERCESC-1477?page=comments#action_12319590 ]
Alberto Massari commented on XERCESC-1477: ------------------------------------------ Keep in mind that XMLString::transcode will convert data into the "current" encoding; the native transcoder will use the local code page as reported by Windows, while ICU will use the ucnv_getDefaultName API. For instance, on my Italian Windows XP, ucnv_getDefaultName returns ibm-5348_P100-1997, while the native transcoder uses the ISO-8859-15 code page. Being potentially different encodings, they could be able to handle the same string in different ways. Please check how these APIs behave on your system; as a suggestion, try to avoid using XMLString::transcode for anything that is not just printing string to the output console, as it has a behaviour that depends on the settings of the user/machine you are running. Alberto > Windows: Unable build Xerces-c with ICU transcode > ------------------------------------------------- > > Key: XERCESC-1477 > URL: http://issues.apache.org/jira/browse/XERCESC-1477 > Project: Xerces-C++ > Type: Bug > Versions: 2.6.0 > Environment: Operating System: Windows XP > Compiler Visual .NET 2003 > Reporter: Ganesh Kumar > Attachments: SAX2Print.exe, simpletext.xml, xerces-c.dll, xerces-c.dll > > I have built Xerces-c with ICU4C 3.2 with icu transcoder. Build was > successful. But the function XMLString::transcode() > does not transcode UTF-8 string properly. But when I built Xerces-c with > native transcoder, the function works fine. Can somebody help me. I am > attaching proper and non-functional dlls. I have a sample program > SAX2Print.exe which uses the function XMLString::transcode(). With the > Xerces-c dll built with native trascoder, it trascode properly, that is , it > prints µ?ú?µ?ú?, which is the correct output. But with the Xerces-c dll > built with ICU transcode, it returns ->->->->. I am attaching the XML > document which has to be transcoded. > To run the sample program, use the command: > SAX2Print.exe -p > simpletext.xml -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
