Buggy code:
public class MessageBodytextViewer extends JTextPane implements Observer , Viewer { private static final Logger LOG = Logger . getLogger ( "org.columba.mail.gui.message.viewer" ) ; private DocumentParser parser ; private HTMLEditorKit htmlEditorKit ; private String css = "" ; private XmlElement smilies ; private boolean enableSmilies ; private String name ; private String size ; private boolean overwrite ; private String body ; private URL url ; private boolean htmlMessage ; public MessageBodytextViewer ( ) { } private boolean hasHtmlPart ( MimePart mimeTypes ) { } public void view ( MessageFolder folder , Object uid , MailFrameMediator mediator ) throws Exception { MimePart bodyPart = null ; InputStream bodyStream ; MimeTree mimePartTree = folder . getMimePartTree ( uid ) ; XmlElement html = config . getMainFrameOptionsConfig ( ) . getRoot ( ) . getElement ( "//options//html" ) ; if ( ( Boolean . valueOf ( html . getAttribute ( "prefer" ) ) . booleanValue ( ) ) && ( hasHtmlPart ( mimePartTree . getRootMimeNode ( ) ) ) ) { bodyPart = mimePartTree . getFirstTextPart ( "html" ) ; } else { bodyPart = mimePartTree . getFirstTextPart ( "plain" ) ; } if ( bodyPart == null ) { bodyStream = new ByteArrayInputStream ( "<No<seq2seq4repair_space>Message-Text>" . getBytes ( ) ) ; } else { htmlMessage = bodyPart . getHeader ( ) . getMimeType ( ) . getSubtype ( ) . equals ( "html" ) ; bodyStream = folder . getMimePartBodyStream ( uid , bodyPart . getAddress ( ) ) ; } Charset charset = ( ( org . columba . core . charset . CharsetOwnerInterface ) ( mediator ) ) . getCharset ( ) ; if ( charset == null ) { String charsetName = null ; if ( bodyPart != null ) { <START_BUG> bodyPart . getHeader ( ) . getContentParameter ( "charset" ) ; <END_BUG> } if ( charsetName == null ) { charsetName = System . getProperty ( "file.encoding" ) ; charset = Charset . forName ( charsetName ) ; } else { try { charset = Charset . forName ( charsetName ) ; } catch ( UnsupportedCharsetException e ) { charsetName = System . getProperty ( "file.encoding" ) ; charset = Charset . forName ( charsetName ) ; } catch ( IllegalCharsetNameException e ) { charsetName = System . getProperty ( "file.encoding" ) ; charset = Charset . forName ( charsetName ) ; } } } int encoding = MimeHeader . PLAIN ; if ( bodyPart != null ) { encoding = bodyPart . getHeader ( ) . getContentTransferEncoding ( ) ; } switch ( encoding ) { case MimeHeader . QUOTED_PRINTABLE : { bodyStream = new QuotedPrintableDecoderInputStream ( bodyStream ) ; break ; } case MimeHeader . BASE64 : { bodyStream = new Base64DecoderInputStream ( bodyStream ) ; break ; } } bodyStream = new CharsetDecoderInputStream ( bodyStream , charset ) ; long startTime = System . currentTimeMillis ( ) ; StringBuffer text = new StringBuffer ( ) ; int next = bodyStream . read ( ) ; while ( next != ( - 1 ) ) { text . append ( ( ( char ) ( next ) ) ) ; next = bodyStream . read ( ) ; } if ( Boolean . valueOf ( html . getAttribute ( "disable" ) ) . booleanValue ( ) ) { setBodyText ( HtmlParser . stripHtmlTags ( text . toString ( ) , true ) , false ) ; htmlMessage = false ; } else { setBodyText ( text . toString ( ) , htmlMessage ) ; } bodyStream . close ( ) ; MessageBodytextViewer . LOG . finer ( ( ( "Needed<seq2seq4repair_space>" + ( ( System . currentTimeMillis ( ) ) - startTime ) ) + "<seq2seq4repair_space>ms<seq2seq4repair_space>" ) ) ; } protected void initStyleSheet ( ) { } protected void setBodyText ( String bodyText , boolean viewHtml ) { } protected String transformToHTML ( StringBuffer buf ) { } public void update ( Observable arg0 , Object arg1 ) { } public void copy ( ) { } public JComponent getView ( ) { } public void updateGUI ( ) throws Exception { } }

Fix:
charsetName = bodyPart . getHeader ( ) . getContentParameter ( "charset" ) ;