jycli 2004/02/05 12:17:28
Modified: java/src/org/apache/xpath/axes UnionPathIterator.java
Log:
Fix for bugzilla bug report 26019
detach location path iterators happens only when allowDetach flag is true.
Reviewed by Henry Zongaro ([EMAIL PROTECTED])
Revision Changes Path
1.32 +10 -11
xml-xalan/java/src/org/apache/xpath/axes/UnionPathIterator.java
Index: UnionPathIterator.java
===================================================================
RCS file:
/home/cvs/xml-xalan/java/src/org/apache/xpath/axes/UnionPathIterator.java,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -r1.31 -r1.32
--- UnionPathIterator.java 22 Oct 2003 18:17:24 -0000 1.31
+++ UnionPathIterator.java 5 Feb 2004 20:17:28 -0000 1.32
@@ -2,7 +2,7 @@
* The Apache Software License, Version 1.1
*
*
- * Copyright (c) 1999-2003 The Apache Software Foundation. All rights
+ * Copyright (c) 1999-2004 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -163,16 +163,15 @@
* exception INVALID_STATE_ERR.
*/
public void detach()
- {
- if(null != m_iterators)
- {
- int n = m_iterators.length;
- for(int i = 0; i < n; i++)
- {
- m_iterators[i].detach();
- }
- m_iterators = null;
- }
+ {
+ if(m_allowDetach && null != m_iterators){
+ int n = m_iterators.length;
+ for(int i = 0; i < n; i++)
+ {
+ m_iterators[i].detach();
+ }
+ m_iterators = null;
+ }
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]