You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2016/08/23 17:02:23 UTC

svn commit: r1757408 - in /tomcat/trunk: java/org/apache/catalina/startup/ContextConfig.java webapps/docs/changelog.xml

Author: markt
Date: Tue Aug 23 17:02:23 2016
New Revision: 1757408

URL: http://svn.apache.org/viewvc?rev=1757408&view=rev
Log:
Improve handling when a WAR file and/or the associated exploded directory are symlinked into the appBase.

Modified:
    tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java
    tomcat/trunk/webapps/docs/changelog.xml

Modified: tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java?rev=1757408&r1=1757407&r2=1757408&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java (original)
+++ tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java Tue Aug 23 17:02:23 2016
@@ -652,6 +652,9 @@ public class ContextConfig implements Li
             }
         }
 
+        // Re-calculate now docBase is a canonical path
+        docBaseInAppBase = docBase.startsWith(appBase.getPath() + File.separatorChar);
+
         if (docBaseInAppBase) {
             docBase = docBase.substring(appBase.getPath().length());
             docBase = docBase.replace(File.separatorChar, '/');

Modified: tomcat/trunk/webapps/docs/changelog.xml
URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1757408&r1=1757407&r2=1757408&view=diff
==============================================================================
--- tomcat/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/trunk/webapps/docs/changelog.xml Tue Aug 23 17:02:23 2016
@@ -167,6 +167,10 @@
         state transition. The exception is now caught and the component is now
         placed into the <code>FAILED</code> state. (markt)
       </fix>
+      <fix>
+        <bug>60022</bug>: Improve handling when a WAR file and/or the associated
+        exploded directory are symlinked into the <code>appBase</code>. (markt)
+      </fix>
     </changelog>
   </subsection>
   <subsection name="Coyote">



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org