changeset 1511:7bd194c33dfa

8242136: Better XML namespace handling Reviewed-by: lancea, dfuchs, skoivu, rhalade, kravikumar, mbalao, andrew
author joehw
date Sun, 12 Jul 2020 16:54:09 +0100
parents c75d23b3a8ff
children 05f76c1ba518
files src/com/sun/org/apache/xerces/internal/impl/xs/XMLSchemaValidator.java
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/com/sun/org/apache/xerces/internal/impl/xs/XMLSchemaValidator.java	Sat Jul 11 20:36:43 2020 +0100
+++ b/src/com/sun/org/apache/xerces/internal/impl/xs/XMLSchemaValidator.java	Sun Jul 12 16:54:09 2020 +0100
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2006, 2020, Oracle and/or its affiliates. All rights reserved.
  */
 /*
  * Licensed to the Apache Software Foundation (ASF) under one or more
@@ -106,6 +106,7 @@
  * @author Andy Clark IBM
  * @author Neeraj Bajaj, Sun Microsystems, inc.
  * @version $Id: XMLSchemaValidator.java,v 1.16 2010-11-01 04:39:55 joehw Exp $
+ * @LastModified: Apr 2020
  */
 public class XMLSchemaValidator
     implements XMLComponent, XMLDocumentFilter, FieldActivator, RevalidationHandler {
@@ -1727,7 +1728,7 @@
 
         // root element
         if (fElementDepth == -1 && fValidationManager.isGrammarFound()) {
-            if (fSchemaType == null) {
+            if (fSchemaType == null && !fUseGrammarPoolOnly) {
                 // schemaType is not specified
                 // if a DTD grammar is found, we do the same thing as Dynamic:
                 // if a schema grammar is found, validation is performed;