summaryrefslogtreecommitdiffstats
path: root/sca-java-2.x/trunk/modules/binding-ws-wsdlgen/src/main
diff options
context:
space:
mode:
authorslaws <slaws@13f79535-47bb-0310-9956-ffa450edef68>2011-08-17 16:04:45 +0000
committerslaws <slaws@13f79535-47bb-0310-9956-ffa450edef68>2011-08-17 16:04:45 +0000
commit9d69b5d4b215f691496a87eea974179a88885383 (patch)
tree39b4b4e5e5e470a019c5d4a4c66a009214c20bf9 /sca-java-2.x/trunk/modules/binding-ws-wsdlgen/src/main
parent1798efc6a2291275dcf9a75b6cc06e64776a5cfa (diff)
TUSCANY-3922 - apply Jennifer's patch to add some missing doPrivileged calls around various classloader calls. Thanks for the patch Jennifer.
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@1158793 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sca-java-2.x/trunk/modules/binding-ws-wsdlgen/src/main')
-rw-r--r--sca-java-2.x/trunk/modules/binding-ws-wsdlgen/src/main/java/org/apache/tuscany/sca/binding/ws/wsdlgen/Interface2WSDLGenerator.java15
1 files changed, 14 insertions, 1 deletions
diff --git a/sca-java-2.x/trunk/modules/binding-ws-wsdlgen/src/main/java/org/apache/tuscany/sca/binding/ws/wsdlgen/Interface2WSDLGenerator.java b/sca-java-2.x/trunk/modules/binding-ws-wsdlgen/src/main/java/org/apache/tuscany/sca/binding/ws/wsdlgen/Interface2WSDLGenerator.java
index 8d80898071..795aae53b8 100644
--- a/sca-java-2.x/trunk/modules/binding-ws-wsdlgen/src/main/java/org/apache/tuscany/sca/binding/ws/wsdlgen/Interface2WSDLGenerator.java
+++ b/sca-java-2.x/trunk/modules/binding-ws-wsdlgen/src/main/java/org/apache/tuscany/sca/binding/ws/wsdlgen/Interface2WSDLGenerator.java
@@ -21,6 +21,9 @@ package org.apache.tuscany.sca.binding.ws.wsdlgen;
import java.lang.reflect.Method;
import java.net.URI;
+import java.security.AccessController;
+import java.security.PrivilegedActionException;
+import java.security.PrivilegedExceptionAction;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
@@ -118,7 +121,17 @@ public class Interface2WSDLGenerator {
this.dataBindings = dataBindings;
this.xsdFactory = xsdFactory;
this.monitor = monitor;
- this.factory = WSDLFactory.newInstance();
+ try{
+ this.factory = AccessController.doPrivileged(new PrivilegedExceptionAction<WSDLFactory>() {
+ public WSDLFactory run() throws WSDLException{
+ WSDLFactory factory = WSDLFactory.newInstance();
+ return factory;
+ }
+ });
+ } catch (PrivilegedActionException e){
+ throw (WSDLException) e.getException();
+ }
+
}
/**