geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From de...@apache.org
Subject svn commit: r922122 [4/4] - in /geronimo/external/branches/tomcat-parent-6.0.26: ./ catalina-ha/ catalina-ha/src/ catalina-ha/src/main/ catalina-ha/src/main/java/ catalina-ha/src/main/java/org/ catalina-ha/src/main/java/org/apache/ catalina-ha/src/main...
Date Fri, 12 Mar 2010 02:34:28 GMT
Modified: geronimo/external/branches/tomcat-parent-6.0.26/util/src/main/java/org/apache/tomcat/util/http/mapper/Mapper.java
URL: http://svn.apache.org/viewvc/geronimo/external/branches/tomcat-parent-6.0.26/util/src/main/java/org/apache/tomcat/util/http/mapper/Mapper.java?rev=922122&r1=921683&r2=922122&view=diff
==============================================================================
--- geronimo/external/branches/tomcat-parent-6.0.26/util/src/main/java/org/apache/tomcat/util/http/mapper/Mapper.java
(original)
+++ geronimo/external/branches/tomcat-parent-6.0.26/util/src/main/java/org/apache/tomcat/util/http/mapper/Mapper.java
Fri Mar 12 02:34:19 2010
@@ -804,6 +804,32 @@ public final class Mapper {
                                         
         }
 
+        // welcome file processing - take 2
+        // take first matching welcome file that has an extension match
+        // a watered down version of rule 4
+        if (mappingData.wrapper == null) {
+            boolean checkWelcomeFiles = checkJspWelcomeFiles;
+            if (!checkWelcomeFiles) {
+                char[] buf = path.getBuffer();
+                checkWelcomeFiles = (buf[pathEnd - 1] == '/');
+            }
+            if (checkWelcomeFiles) {
+                for (int i = 0; (i < context.welcomeResources.length)
+                         && (mappingData.wrapper == null); i++) {
+                    path.setOffset(pathOffset);
+                    path.setEnd(pathEnd);
+                    path.append(context.welcomeResources[i], 0,
+                                context.welcomeResources[i].length());
+                    path.setOffset(servletPath);
+                    internalMapExtensionWrapper(extensionWrappers,
+                                                path, mappingData);
+                }
+
+                path.setOffset(servletPath);
+                path.setEnd(pathEnd);
+            }
+        }
+
 
         // Rule 7 -- Default servlet
         if (mappingData.wrapper == null && !checkJspWelcomeFiles) {



Mime
View raw message