DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=37029>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=37029


[EMAIL PROTECTED] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED




------- Additional Comments From [EMAIL PROTECTED]  2005-12-10 01:17 -------
The html <param> is being treated incorrectly as an <fmt:param> tag,
because of this code in JstlBaseTLV:

    protected boolean isTag(String tagUri,
                            String tagLn,
                            String matchUri,
                            String matchLn) {
        if (tagUri == null
                || tagLn == null
                || matchUri == null
                || matchLn == null)
            return false;

        if (tagUri.length() > matchUri.length()) {
            return (tagUri.startsWith(matchUri)
                    && tagLn.equals(matchLn));
        } else {
            return (matchUri.startsWith(tagUri)
                    && tagLn.equals(matchLn));
        }

In the test case, isTag() is invoked with these args:

  tagUri=""
  tagLn="param"
  matchUri="http://java.sun.com/jsp/jstl/fmt";
  matchLn="param"

which means the "else" will return TRUE, since any string starts with
the empty string!

The fix is to return FALSE if the "tagUri" param is NULL or the EMPTY
string, as shown in these diffs:

--- JstlBaseTLV.java    8 Dec 2005 01:21:24 -0000
+++ JstlBaseTLV.java    10 Dec 2005 00:01:32 -0000
@@ -210,6 +210,7 @@
                            String matchUri,
                            String matchLn) {
        if (tagUri == null
+                || tagUri.length() == 0
                || tagLn == null
                || matchUri == null
                || matchLn == null)

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to