You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@cocoon.apache.org by jo...@apache.org on 2006/10/02 19:41:46 UTC
svn commit: r452142 - in
/cocoon/trunk/blocks/cocoon-template/cocoon-template-impl:
src/main/java/org/apache/cocoon/template/instruction/Comment.java status.xml
Author: joerg
Date: Mon Oct 2 10:41:45 2006
New Revision: 452142
URL: http://svn.apache.org/viewvc?view=rev&rev=452142
Log:
COCOON-1866: Fix ArrayIndexOutOfBoundsException with jx:comment
Modified:
cocoon/trunk/blocks/cocoon-template/cocoon-template-impl/src/main/java/org/apache/cocoon/template/instruction/Comment.java
cocoon/trunk/blocks/cocoon-template/cocoon-template-impl/status.xml
Modified: cocoon/trunk/blocks/cocoon-template/cocoon-template-impl/src/main/java/org/apache/cocoon/template/instruction/Comment.java
URL: http://svn.apache.org/viewvc/cocoon/trunk/blocks/cocoon-template/cocoon-template-impl/src/main/java/org/apache/cocoon/template/instruction/Comment.java?view=diff&rev=452142&r1=452141&r2=452142
==============================================================================
--- cocoon/trunk/blocks/cocoon-template/cocoon-template-impl/src/main/java/org/apache/cocoon/template/instruction/Comment.java (original)
+++ cocoon/trunk/blocks/cocoon-template/cocoon-template-impl/src/main/java/org/apache/cocoon/template/instruction/Comment.java Mon Oct 2 10:41:45 2006
@@ -28,7 +28,6 @@
import org.apache.cocoon.template.script.event.StartElement;
import org.apache.cocoon.xml.XMLConsumer;
import org.apache.cocoon.xml.XMLUtils;
-import org.apache.commons.lang.StringUtils;
import org.w3c.dom.NodeList;
import org.xml.sax.Attributes;
import org.xml.sax.SAXException;
@@ -58,9 +57,7 @@
Properties omit = XMLUtils.createPropertiesForXML(true);
for (int i = 0; i < len; i++) {
try {
- String str = XMLUtils.serializeNode(nodeList.item(i), omit);
- buf.append(StringUtils.substringAfter(str, ">")); // cut
- // the XML header
+ buf.append(XMLUtils.serializeNode(nodeList.item(i), omit));
} catch (ProcessingException e) {
throw new SAXParseException(e.getMessage(), getLocation(), e);
}
Modified: cocoon/trunk/blocks/cocoon-template/cocoon-template-impl/status.xml
URL: http://svn.apache.org/viewvc/cocoon/trunk/blocks/cocoon-template/cocoon-template-impl/status.xml?view=diff&rev=452142&r1=452141&r2=452142
==============================================================================
--- cocoon/trunk/blocks/cocoon-template/cocoon-template-impl/status.xml (original)
+++ cocoon/trunk/blocks/cocoon-template/cocoon-template-impl/status.xml Mon Oct 2 10:41:45 2006
@@ -66,6 +66,9 @@
<!-- The following list contains the changes since the latest 2.1.x version. -->
<changes>
<release version="@version@" date="@date@">
+ <action dev="JH" type="fix" fixes-bug="COCOON-1866" due-to="Ellis Pritchard" due-to-email="ellis@nukinetics.com">
+ Fix an ArrrayIndexOutOfBoundsException with jx:comment.
+ </action>
<action dev="LG" type="add">
New syntax for jx:attribute tag: apart from <jx:atttribute name="text" value="abc"/> one can do:
<jx:atttribute name="text">abc</jx:attribute> This is most useful for nesting jx:* tags: