Revision: 5916
Author: [email protected]
Date: Fri Aug  7 12:47:58 2009
Log: Hacky fix to not break tomcat when java 1.5 is used in presence of the  
xercesImpl lib.

Patch by: amitmanjhi
Review by: rjrjr (desk review)


http://code.google.com/p/google-web-toolkit/source/detail?r=5916

Modified:
   
/trunk/dev/core/src/com/google/gwt/dev/shell/tomcat/EmbeddedTomcatServer.java

=======================================
---  
/trunk/dev/core/src/com/google/gwt/dev/shell/tomcat/EmbeddedTomcatServer.java   
 
Fri Mar 27 08:09:11 2009
+++  
/trunk/dev/core/src/com/google/gwt/dev/shell/tomcat/EmbeddedTomcatServer.java   
 
Fri Aug  7 12:47:58 2009
@@ -177,6 +177,15 @@
      //
      File topWorkDir = new File(System.getProperty("user.dir"));

+    /*
+     * set property explicitly so that addition of the xercesImpl lib,  
when java
+     * 1.5 is used, does not affect tomcat.
+     */
+    if ("1.5".equals(System.getProperty("java.specification.version"))) {
+      System.setProperty("javax.xml.parsers.DocumentBuilderFactory",
+          
"com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl");
+    }
+
      // Tell Tomcat its base directory so that it won't complain.
      //
      String catBase = System.getProperty("catalina.base");

--~--~---------~--~----~------------~-------~--~----~
http://groups.google.com/group/Google-Web-Toolkit-Contributors
-~----------~----~----~----~------~----~------~--~---

Reply via email to