< prev index next >

src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/XMLStreamReaderImpl.java

Print this page

        

@@ -1,7 +1,7 @@
 /*
- * Copyright (c) 2005, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2016, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
  * under the terms of the GNU General Public License version 2 only, as
  * published by the Free Software Foundation.  Oracle designates this

@@ -605,11 +605,12 @@
         fScanner = new XML11NSDocumentScannerImpl();
 
         //get the new scanner state to old scanner's previous state
         fScanner.reset(fPropertyManager);
         fScanner.setPropertyManager(fPropertyManager);
-        fEntityScanner = (XMLEntityScanner)fEntityManager.getEntityScanner()  ;
+        fEntityScanner = fEntityManager.getEntityScanner();
+        fEntityScanner.registerListener(fScanner);
         fEntityManager.fCurrentEntity.mayReadChunks = true;
         fScanner.setScannerState(XMLEvent.START_DOCUMENT);
 
         fScanner.fEntityDepth = oldEntityDepth;
         fScanner.fNamespaceContext = oldNamespaceContext;
< prev index next >