Bug 8142 - MS_Kanji to SJIS conversion problem
Summary: MS_Kanji to SJIS conversion problem
Status: NEW
Alias: None
Product: Xerces-J
Classification: Unclassified
Component: SAX (show other bugs)
Version: 1.4.4
Hardware: All All
: P3 normal
Target Milestone: ---
Assignee: Xerces-J Developers Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-04-16 03:11 UTC by Mohammad M. Purbo
Modified: 2004-11-16 19:05 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mohammad M. Purbo 2002-04-16 03:11:08 UTC
On org.apache.xerces.readers.MIME2Java, there is this one line:

s_enchash.put("MS_Kanji",       "SJIS");

But, that s_enchash hashtable is used in convert method in the following manner:

return (String)s_enchash.get(mimeCharsetName.toUpperCase());

Because all mimeCharsetName is set to upper case (thus, converting "MS_Kanji" 
to "MS_KANJI"), then if the XML is having charset="MS_Kanji", an 
UnsupportedCharacterEncoding would be thrown.