tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r1664710 - in /tomcat/trunk/java/org/apache/jasper: JspCompilationContext.java compiler/TagLibraryInfoImpl.java
Date Fri, 06 Mar 2015 19:31:56 GMT
Author: markt
Date: Fri Mar  6 19:31:55 2015
New Revision: 1664710

URL: http://svn.apache.org/r1664710
Log:
Fix https://bz.apache.org/bugzilla/show_bug.cgi?id=57627
Correctly determine last modified times for dependencies when a tag file packaged in a JAR
depends on a tag file packaged in a second JAR.

Modified:
    tomcat/trunk/java/org/apache/jasper/JspCompilationContext.java
    tomcat/trunk/java/org/apache/jasper/compiler/TagLibraryInfoImpl.java

Modified: tomcat/trunk/java/org/apache/jasper/JspCompilationContext.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/jasper/JspCompilationContext.java?rev=1664710&r1=1664709&r2=1664710&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/jasper/JspCompilationContext.java (original)
+++ tomcat/trunk/java/org/apache/jasper/JspCompilationContext.java Fri Mar  6 19:31:55 2015
@@ -351,7 +351,13 @@ public class JspCompilationContext {
         return jspUri;
     }
 
+
     public Long getLastModified(String resource) {
+        return getLastModified(resource, tagJar);
+    }
+
+
+    public Long getLastModified(String resource, Jar tagJar) {
         long result = -1;
         URLConnection uc = null;
         try {

Modified: tomcat/trunk/java/org/apache/jasper/compiler/TagLibraryInfoImpl.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/jasper/compiler/TagLibraryInfoImpl.java?rev=1664710&r1=1664709&r2=1664710&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/jasper/compiler/TagLibraryInfoImpl.java (original)
+++ tomcat/trunk/java/org/apache/jasper/compiler/TagLibraryInfoImpl.java Fri Mar  6 19:31:55
2015
@@ -134,7 +134,10 @@ class TagLibraryInfoImpl extends TagLibr
                 String path = tldResourcePath.getWebappPath();
                 if (path != null) {
                     // Add TLD (jar==null) / JAR (jar!=null) file to dependency list
-                    pageInfo.addDependant(path, ctxt.getLastModified(path));
+                    // 2nd parameter is null since the path is always relative
+                    // to the root of the web application even if we are
+                    // processing a reference from a tag packaged in a JAR.
+                    pageInfo.addDependant(path, ctxt.getLastModified(path, null));
                 }
                 if (jar != null) {
                     if (path == null) {



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


Mime
View raw message