You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by am...@apache.org on 2004/12/06 12:50:30 UTC
cvs commit: xml-xerces/c/src/xercesc/dom/impl DOMNodeIteratorImpl.cpp
amassari 2004/12/06 03:50:30
Modified: c/src/xercesc/dom/impl DOMNodeIteratorImpl.cpp
Log:
Take into account the fExpandEntityReferences setting [jira# 1303]
Revision Changes Path
1.9 +5 -3 xml-xerces/c/src/xercesc/dom/impl/DOMNodeIteratorImpl.cpp
Index: DOMNodeIteratorImpl.cpp
===================================================================
RCS file: /home/cvs/xml-xerces/c/src/xercesc/dom/impl/DOMNodeIteratorImpl.cpp,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- DOMNodeIteratorImpl.cpp 8 Sep 2004 13:55:52 -0000 1.8
+++ DOMNodeIteratorImpl.cpp 6 Dec 2004 11:50:30 -0000 1.9
@@ -250,7 +250,8 @@
// only check children if we visit children.
if (visitChildren) {
//if hasChildren, return 1st child.
- if (node->hasChildNodes()) {
+ if ((fExpandEntityReferences || node->getNodeType()!=DOMNode::ENTITY_REFERENCE_NODE) &&
+ node->hasChildNodes()) {
result = node->getFirstChild();
return result;
}
@@ -303,7 +304,8 @@
// if sibling has children, keep getting last child of child.
if (result->hasChildNodes()) {
- while (result->hasChildNodes()) {
+ while ((fExpandEntityReferences || result->getNodeType()!=DOMNode::ENTITY_REFERENCE_NODE) &&
+ result->hasChildNodes()) {
result = result->getLastChild();
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-cvs-help@xml.apache.org