incubator-jspwiki-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Simon Kitching (JIRA)" <j...@apache.org>
Subject [jira] Created: (JSPWIKI-388) ParamTag loops forever when parent tag is not ParamHandler
Date Mon, 29 Sep 2008 09:08:44 GMT
ParamTag loops forever when parent tag is not ParamHandler
----------------------------------------------------------

                 Key: JSPWIKI-388
                 URL: https://issues.apache.org/jira/browse/JSPWIKI-388
             Project: JSPWiki
          Issue Type: Bug
          Components: Core & storage
    Affects Versions: 2.6.3
            Reporter: Simon Kitching


I recently tried to use tag wiki:Param within a wiki:UploadLink tag, and the page immediately
hung. It appears that this combination is not supported (ok), but the infinite loop is presumably
not intended.

The problem is with this code in class ParamTag:

    public int doEndTag()
    {
        Tag t = null;
        while( (t = getParent()) != null && !(t instanceof ParamHandler) )
            ;
        ...
     }

This code is the same in both jspwiki 2.6.3 (which I am using) and current svn trunk.

This loops endlessly if the parent of the ParamTag is not a ParamHandler, because getParent()
returns the same object each time. Maybe t.getParent() was intended? (although that won't
work on the first call when t is null).

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message