tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r932797 - in /tomcat/tc5.5.x/trunk: STATUS.txt container/webapps/docs/changelog.xml container/webapps/docs/config/systemprops.xml jasper/src/share/org/apache/jasper/compiler/Generator.java
Date Sat, 10 Apr 2010 22:23:58 GMT
Author: markt
Date: Sat Apr 10 22:23:57 2010
New Revision: 932797

URL: http://svn.apache.org/viewvc?rev=932797&view=rev
Log:
Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=48701
Add system property to allow disabling enforcement of JSP.5.3. The spec recommends, but does
not require this enforcement. (kkolinko)

Modified:
    tomcat/tc5.5.x/trunk/STATUS.txt
    tomcat/tc5.5.x/trunk/container/webapps/docs/changelog.xml
    tomcat/tc5.5.x/trunk/container/webapps/docs/config/systemprops.xml
    tomcat/tc5.5.x/trunk/jasper/src/share/org/apache/jasper/compiler/Generator.java

Modified: tomcat/tc5.5.x/trunk/STATUS.txt
URL: http://svn.apache.org/viewvc/tomcat/tc5.5.x/trunk/STATUS.txt?rev=932797&r1=932796&r2=932797&view=diff
==============================================================================
--- tomcat/tc5.5.x/trunk/STATUS.txt (original)
+++ tomcat/tc5.5.x/trunk/STATUS.txt Sat Apr 10 22:23:57 2010
@@ -101,13 +101,6 @@ PATCHES PROPOSED TO BACKPORT:
   -1:
 
 * Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=48701
-  Add system property to allow disabling enforcement of JSP.5.3
-  The spec recommends, but does not require this enforcement.
-  http://svn.apache.org/viewvc?rev=920880&view=rev
-  +1: kkolinko, markt, rjung
-  -1:
-
-* Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=48701
   Tag account of TagVariableInfo when implementing the rules of JSP.5.3
   http://people.apache.org/~markt/patches/2010-03-09-bug48701.patch
   +1: markt, kkolinko

Modified: tomcat/tc5.5.x/trunk/container/webapps/docs/changelog.xml
URL: http://svn.apache.org/viewvc/tomcat/tc5.5.x/trunk/container/webapps/docs/changelog.xml?rev=932797&r1=932796&r2=932797&view=diff
==============================================================================
--- tomcat/tc5.5.x/trunk/container/webapps/docs/changelog.xml (original)
+++ tomcat/tc5.5.x/trunk/container/webapps/docs/changelog.xml Sat Apr 10 22:23:57 2010
@@ -49,6 +49,15 @@
       </fix>
     </changelog>
   </subsection>
+  <subsection name="Jasper">
+    <changelog>
+      <fix>
+        <bug>48701</bug>: Add a system property to allow disabling enforcement
+        of JSP.5.3. The specification recommends, but does not require, this
+        enforcement. (kkolinko)
+      </fix>
+    </changelog>
+  </subsection>
 </section>
 <section name="Tomcat 5.5.29 (fhanik)">
   <subsection name="General">

Modified: tomcat/tc5.5.x/trunk/container/webapps/docs/config/systemprops.xml
URL: http://svn.apache.org/viewvc/tomcat/tc5.5.x/trunk/container/webapps/docs/config/systemprops.xml?rev=932797&r1=932796&r2=932797&view=diff
==============================================================================
--- tomcat/tc5.5.x/trunk/container/webapps/docs/config/systemprops.xml (original)
+++ tomcat/tc5.5.x/trunk/container/webapps/docs/config/systemprops.xml Sat Apr 10 22:23:57
2010
@@ -38,6 +38,14 @@
 <section name="Jasper">
   <properties>
 
+    <property name="org.apache.jasper.compiler. Generator.STRICT_GET_PROPERTY">
+      <p>If <code>true</code>, the requirement to have the object referenced
in
+      <code>jsp:getProperty</code> action to be previously "introduced"
+      to the JSP processor, as specified in the chapter JSP.5.3 of JSP 2.0 and
+      later specifications, is enforced. If not specified, the specification
+      compliant default of <code>true</code> will be used.</p>
+    </property>
+
 	<property name="org.apache.jasper.compiler. Parser.STRICT_QUOTE_ESCAPING">
 	  <p>If <code>false</code> the requirements for escaping quotes in JSP
       attributes will be relaxed so that an unescaped quote will not

Modified: tomcat/tc5.5.x/trunk/jasper/src/share/org/apache/jasper/compiler/Generator.java
URL: http://svn.apache.org/viewvc/tomcat/tc5.5.x/trunk/jasper/src/share/org/apache/jasper/compiler/Generator.java?rev=932797&r1=932796&r2=932797&view=diff
==============================================================================
--- tomcat/tc5.5.x/trunk/jasper/src/share/org/apache/jasper/compiler/Generator.java (original)
+++ tomcat/tc5.5.x/trunk/jasper/src/share/org/apache/jasper/compiler/Generator.java Sat Apr
10 22:23:57 2010
@@ -66,6 +66,16 @@ import org.xml.sax.Attributes;
 class Generator {
 
     private static final Class[] OBJECT_CLASS = { Object.class };
+    
+    /* System property that controls if the requirement to have the object
+     * used in jsp:getProperty action to be previously "introduced"
+     * to the JSP processor (see JSP.5.3) is enforced.
+     */ 
+    private static final boolean STRICT_GET_PROPERTY = Boolean.valueOf(
+            System.getProperty(
+                    "org.apache.jasper.compiler.Generator.STRICT_GET_PROPERTY",
+                    "true")).booleanValue();
+
     private ServletWriter out;
     private ArrayList methodsBuffered;
     private FragmentHelperClass fragmentHelperClass;
@@ -1030,7 +1040,7 @@ class Generator {
                         + "\"))."
                         + methodName
                         + "())));");
-            } else if (varInfoNames.contains(name)){
+            } else if (!STRICT_GET_PROPERTY || varInfoNames.contains(name)){
                 // The object is a custom action with an associated
                 // VariableInfo entry for this name.
                 // Get the class name and then introspect at runtime.



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


Mime
View raw message