Affects Version/s: None
Fix Version/s: 1.4.4
Number of attachments :
The xml pull parser in plexus-utils(MXParser.java) can't handle the encoding declaration in XML declaration.
So, it's impossible to use an encoding different from system default encoding. This is critical in Japan, because
there is two commonly used encodings in Japanese environment(SJIS and EUC-JP).
I think MXParser should handle encoding declaration in xml as described in w3c specification/
I tried to fix this problem(see attachment).
I changed the setInput(InputStream) method to detect encoding in xml declaration.
For writing this code, I referred to source code of Apache Xerces.
UCS-4 and UCS-2 isn't supported in this implementation, because
these encoding isn't supported by Sun JDK.
Xerces solves this problem by providing original reader for these encodings. I think Xerces's solution is
too complex for plexus-utils.
To solve this issue, it's not sufficient only to change plexus-utils, because
DefaultMavenProjectBuilder reads POM by FileReader without specifying encoding.