tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 21711] - Error when compiling a JSP that uses a TLD 1.1
Date Sat, 19 Jul 2003 20:54:42 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21711>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21711

Error when compiling a JSP that uses a TLD 1.1

ecarmich@alumni.rice.edu changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |INVALID



------- Additional Comments From ecarmich@alumni.rice.edu  2003-07-19 20:54 -------
I believe Tomcat's behavior here is consistent with the JSP 1.1 
specification.  Your example works if the attribute is renamed to something 
other than "id", or if the attribute value is not specified as a request-time 
attribute value.  The error only occurs when specifying a request-time 
attribute value for a parameter named "id".

The spec mandates special treatment of attributes named "id", as detailed in 
section 2.12.2:

'The id="name" attribute/value tuple in an element has special meaning to a 
JSP container, both at page translation time, and at client request processing 
time; in particular: 
 the name must be unique within the translation unit, and identifies the 
particular element in which it appears to the JSP container and page.'

"name must be unique within the translation unit" to me implies "name" cannot 
be a request-time attribute value, as if it were, there would be no way to 
verify uniqueness at translation time.  The spec seems to make this explicit 
in a parenthetical in section 5.1.3.2: "note that id must be a translation-
time attribute".

The code seems to be consistent with this interpretation.  The actual 
exception is thrown by code that I don't have access to, but it's clear from 
the Javadocs that the problem is that TagData.getID expects the value of 
the "id" attribute to be a String (as it would be if it were a translation-
time attribute), whereas Tomcat has set it to TagData.REQUEST_TIME_VALUE, as 
is proper for a request-time attribute value.

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


Mime
View raw message