You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by an...@apache.org on 2001/07/16 10:09:35 UTC
cvs commit: xml-xerces/java/src/org/apache/xerces/impl/validation Grammar.java
andyc 01/07/16 01:09:35
Modified: java/src/org/apache/xerces/impl/validation Tag: xerces_j_2
Grammar.java
Log:
Fixed NullPointerException.
Revision Changes Path
No revision
No revision
1.1.2.33 +3 -2 xml-xerces/java/src/org/apache/xerces/impl/validation/Attic/Grammar.java
Index: Grammar.java
===================================================================
RCS file: /home/cvs/xml-xerces/java/src/org/apache/xerces/impl/validation/Attic/Grammar.java,v
retrieving revision 1.1.2.32
retrieving revision 1.1.2.33
diff -u -r1.1.2.32 -r1.1.2.33
--- Grammar.java 2001/02/13 18:36:15 1.1.2.32
+++ Grammar.java 2001/07/16 08:09:35 1.1.2.33
@@ -95,7 +95,7 @@
* @author Eric Ye, IBM
* @author Andy Clark, IBM
*
- * @version $Id: Grammar.java,v 1.1.2.32 2001/02/13 18:36:15 lehors Exp $
+ * @version $Id: Grammar.java,v 1.1.2.33 2001/07/16 08:09:35 andyc Exp $
*/
public abstract class Grammar {
@@ -1464,7 +1464,8 @@
// Its not a leaf, so we have to recurse its left and maybe right
// nodes. Save both values before we recurse and trash the node.
//
- final int leftNode = ((int[])(contentSpec.value))[0];
+ final int leftNode = contentSpec.value != null
+ ? ((int[])(contentSpec.value))[0] : -1;
int rightNode = -1 ;
if (contentSpec.otherValue != null )
rightNode = ((int[])(contentSpec.otherValue))[0];
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-cvs-help@xml.apache.org