You are viewing a plain text version of this content. The canonical link for it is here.
Posted to scm@geronimo.apache.org by dj...@apache.org on 2005/10/01 02:08:37 UTC

svn commit: r292880 - /geronimo/branches/1.0-M5/modules/tomcat-builder/src/java/org/apache/geronimo/tomcat/deployment/TomcatModuleBuilder.java

Author: djencks
Date: Fri Sep 30 17:08:35 2005
New Revision: 292880

URL: http://svn.apache.org/viewcvs?rev=292880&view=rev
Log:
GERONIMO-1031, avoid NPE when looking for context-root

Modified:
    geronimo/branches/1.0-M5/modules/tomcat-builder/src/java/org/apache/geronimo/tomcat/deployment/TomcatModuleBuilder.java

Modified: geronimo/branches/1.0-M5/modules/tomcat-builder/src/java/org/apache/geronimo/tomcat/deployment/TomcatModuleBuilder.java
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.0-M5/modules/tomcat-builder/src/java/org/apache/geronimo/tomcat/deployment/TomcatModuleBuilder.java?rev=292880&r1=292879&r2=292880&view=diff
==============================================================================
--- geronimo/branches/1.0-M5/modules/tomcat-builder/src/java/org/apache/geronimo/tomcat/deployment/TomcatModuleBuilder.java (original)
+++ geronimo/branches/1.0-M5/modules/tomcat-builder/src/java/org/apache/geronimo/tomcat/deployment/TomcatModuleBuilder.java Fri Sep 30 17:08:35 2005
@@ -194,7 +194,11 @@
         }
 
         if (contextRoot == null) {
-            contextRoot = tomcatWebApp.getContextRoot();
+            if (tomcatWebApp.isSetContextRoot()) {
+                contextRoot = tomcatWebApp.getContextRoot();
+            } else {
+                contextRoot = determineDefaultContextRoot(webApp, standAlone, moduleFile, targetPath);
+            }
         }
         //look for a webservices dd
         Map portMap = Collections.EMPTY_MAP;