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=18314>. 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=18314 Multiple declarations of same taglib cause exception during validation ------- Additional Comments From [EMAIL PROTECTED] 2003-03-25 12:51 ------- The bug appears to be in org.apache.jasper.compiler.PageDataImpl. The FirstPassVisitor which builds up the xmlns attributes in the visit(Node.TaglibDirective) method isn't checking for the presence of an existing attribute within the existing collection (and instance of AttributesImpl). The javadoc for the addAttribute method in the AttributesImpl class (http://www.saxproject.org/apidoc/org/xml/sax/helpers/AttributesImpl.html) explains that: "For the sake of speed, this method does no checking to see if the attribute is already in the list: that is the responsibility of the application." The FirstPassVisitor class should therefore perform an extra test before calling addAttribute. Something like this for e.g: if (attrs != null) { String type = "xmlns:" + attrs.getValue("prefix"); if (attrs.getIndex(type) == -1) { ...existing code... } } Removing the duplicate attributes will solve the later validation problems. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]