[ https://issues.apache.org/jira/browse/XALANJ-1621?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12662057#action_12662057 ]
Jochen Schwarze commented on XALANJ-1621: ----------------------------------------- Please consider implementing EXSLT's document method <http://www.exslt.org/exsl/elements/document/index.html>. This allows all output parameters to be explicitly set for the secondary files. > Wrong encoding with redirect:write in xsltc > ------------------------------------------- > > Key: XALANJ-1621 > URL: https://issues.apache.org/jira/browse/XALANJ-1621 > Project: XalanJ2 > Issue Type: Bug > Security Level: No security risk; visible to anyone(Ordinary problems in > Xalan projects. Anybody can view the issue.) > Components: XSLTC > Affects Versions: 2.5Dx > Environment: Operating System: All > Platform: All > Reporter: Franz Fackelmann > Assignee: Xalan Developers Mailing List > > When using redirect:write with translets made by XSLTC (Xalan-J 2.5.1) the > output is in the wrong encoding. Instead of the encoding specified in the > xslt:output element the output is in the default OS encoding. The following > patch should fix the problem (class > org.apache.xalan.xsltc.runtime.AbstractTranslet): > 68c68,76 > < import java.io.FileWriter; > --- > > import java.io.File; > > import java.io.FileOutputStream; > > import java.io.OutputStream; > > > > import java.io.Writer; > > import java.io.OutputStreamWriter; > > import java.io.BufferedWriter; > > import java.io.FileOutputStream; > > > 486c494,495 > < factory.setWriter(new FileWriter(filename, append)); > --- > > FileOutputStream fs = new FileOutputStream (filename, append); > > factory.setWriter(new BufferedWriter(new OutputStreamWriter(fs, > > _encoding))); -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: xalan-dev-unsubscr...@xml.apache.org For additional commands, e-mail: xalan-dev-h...@xml.apache.org