--- a/jaxp/src/com/sun/xml/internal/stream/writers/XMLStreamWriterImpl.java Wed Jul 05 18:46:58 2017 +0200
+++ b/jaxp/src/com/sun/xml/internal/stream/writers/XMLStreamWriterImpl.java Mon Feb 18 11:33:35 2013 -0800
@@ -53,6 +53,7 @@
import com.sun.org.apache.xerces.internal.impl.PropertyManager;
import com.sun.org.apache.xerces.internal.util.NamespaceSupport;
import com.sun.org.apache.xerces.internal.util.SymbolTable;
+import com.sun.org.apache.xerces.internal.utils.SecuritySupport;
import com.sun.org.apache.xerces.internal.xni.QName;
import com.sun.xml.internal.stream.util.ReadOnlyIterator;
@@ -340,7 +341,7 @@
fEncoder = Charset.forName(encoding).newEncoder();
}
} else {
- encoding = System.getProperty("file.encoding");
+ encoding = SecuritySupport.getSystemProperty("file.encoding");
if (encoding != null && encoding.equalsIgnoreCase("utf-8")) {
fWriter = new UTF8OutputStreamWriter(os);
} else {