1.1 --- a/src/share/jaxws_classes/com/sun/tools/internal/xjc/reader/xmlschema/BGMBuilder.java Thu Apr 04 19:05:24 2013 -0700 1.2 +++ b/src/share/jaxws_classes/com/sun/tools/internal/xjc/reader/xmlschema/BGMBuilder.java Tue Apr 09 14:51:13 2013 +0100 1.3 @@ -1,5 +1,5 @@ 1.4 /* 1.5 - * Copyright (c) 1997, 2011, Oracle and/or its affiliates. All rights reserved. 1.6 + * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. 1.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 1.8 * 1.9 * This code is free software; you can redistribute it and/or modify it 1.10 @@ -57,6 +57,7 @@ 1.11 import com.sun.tools.internal.xjc.util.CodeModelClassFactory; 1.12 import com.sun.tools.internal.xjc.util.ErrorReceiverFilter; 1.13 import com.sun.xml.internal.bind.api.impl.NameConverter; 1.14 +import com.sun.xml.internal.bind.v2.util.XmlFactory; 1.15 import com.sun.xml.internal.xsom.XSAnnotation; 1.16 import com.sun.xml.internal.xsom.XSAttributeUse; 1.17 import com.sun.xml.internal.xsom.XSComponent; 1.18 @@ -228,7 +229,7 @@ 1.19 } 1.20 1.21 // obtain the name conversion mode 1.22 - if(globalBinding.nameConverter!=null) 1.23 + if (globalBinding.nameConverter!=null) 1.24 model.setNameConverter(globalBinding.nameConverter); 1.25 1.26 // attach global conversions to the appropriate simple types 1.27 @@ -498,8 +499,10 @@ 1.28 */ 1.29 public Transformer getIdentityTransformer() { 1.30 try { 1.31 - if(identityTransformer==null) 1.32 - identityTransformer = TransformerFactory.newInstance().newTransformer(); 1.33 + if(identityTransformer==null) { 1.34 + TransformerFactory tf = XmlFactory.createTransformerFactory(model.options.disableXmlSecurity); 1.35 + identityTransformer = tf.newTransformer(); 1.36 + } 1.37 return identityTransformer; 1.38 } catch (TransformerConfigurationException e) { 1.39 throw new Error(e); // impossible