You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by "Timm, Sean" <ST...@mailgo.com> on 2000/01/24 09:18:49 UTC
[PATCH] Fix for Null Pointer Exception during call to Utils.getAl
lPIs
Index: Utils.java
===================================================================
RCS file: /home/cvspublic/xml-cocoon/src/org/apache/cocoon/Utils.java,v
retrieving revision 1.5
diff -u -r1.5 Utils.java
--- Utils.java 2000/01/23 23:14:11 1.5
+++ Utils.java 2000/01/24 08:13:50
@@ -88,7 +88,10 @@
if (node.getNodeType() == Node.PROCESSING_INSTRUCTION_NODE) {
if (((ProcessingInstruction)
node).getTarget().equals(name)) {
pis.addElement(node);
- if (remove) node.getParentNode().removeChild(node);
+ if (remove) {
+ node.getParentNode().removeChild(node);
+ i--;
+ }
}
}
}