changeset 961:0a061fe10cd8

8062518: AIOBE occurs when accessing to document function in extended function in JAXP Reviewed-by: joehw
author aefimov
date Mon, 11 May 2015 12:48:57 +0300
parents 040ce4bf5a41
children 0262b5e33bc4
files src/com/sun/org/apache/xalan/internal/xsltc/dom/MultiDOM.java
diffstat 1 files changed, 6 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/com/sun/org/apache/xalan/internal/xsltc/dom/MultiDOM.java	Wed May 06 13:12:04 2015 -0700
+++ b/src/com/sun/org/apache/xalan/internal/xsltc/dom/MultiDOM.java	Mon May 11 12:48:57 2015 +0300
@@ -567,8 +567,12 @@
     }
 
     public NodeList makeNodeList(DTMAxisIterator iter) {
-        // TODO: gather nodes from all DOMs ?
-        return _main.makeNodeList(iter);
+        int index = iter.next();
+        if (index == DTM.NULL) {
+            return null;
+        }
+        iter.reset();
+        return _adapters[getDTMId(index)].makeNodeList(iter);
     }
 
     public String getLanguage(int node) {