Author: mukulg
Date: Sun Mar 26 07:14:41 2023
New Revision: 1908723

URL: http://svn.apache.org/viewvc?rev=1908723&view=rev
Log:
xercesj commit : committing fix for jira issue XERCESJ-1754

Modified:
    
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java

Modified: 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java
URL: 
http://svn.apache.org/viewvc/xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java?rev=1908723&r1=1908722&r2=1908723&view=diff
==============================================================================
--- 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java
 (original)
+++ 
xerces/java/branches/xml-schema-1.1-dev/src/org/apache/xerces/impl/xs/XMLSchemaValidator.java
 Sun Mar 26 07:14:41 2023
@@ -760,12 +760,7 @@ public class XMLSchemaValidator extends
      *
      * @param componentManager The component manager.
      *
-     * @throws SAXException Thrown by component on finitialization error.
-     *                      For example, if a feature or property is
-     *                      required for the operation of the component, the
-     *                      component manager may throw a
-     *                      SAXNotRecognizedException or a
-     *                      SAXNotSupportedException.
+     * @throws XMLConfigurationException
      */
     public void reset(XMLComponentManager componentManager) throws 
XMLConfigurationException {
 
@@ -799,27 +794,26 @@ public class XMLSchemaValidator extends
 
         // get error reporter
         fXSIErrorReporter.reset((XMLErrorReporter) 
componentManager.getProperty(ERROR_REPORTER));
-
-        boolean parser_settings;
+        
         try {
-            parser_settings = componentManager.getFeature(PARSER_SETTINGS);
+            boolean parser_settings = 
componentManager.getFeature(PARSER_SETTINGS);
+            
+            if (!parser_settings) {
+                // parser settings feature is not supported                
+                
+                fValidationManager.addValidationState(fValidationState);
+                // the node limit on the SecurityManager may have changed so 
need to refresh
+                nodeFactory.reset();
+                // Re-parse external schema location properties
+                XMLSchemaLoader.processExternalHints(
+                                           fExternalSchemas,
+                                           fExternalNoNamespaceSchema,
+                                           fLocationPairs,
+                                           fXSIErrorReporter.fErrorReporter);
+            }
         }
         catch (XMLConfigurationException e){
-            parser_settings = true;
-        }
-
-        if (!parser_settings) {
-            // parser settings have not been changed
-            fValidationManager.addValidationState(fValidationState);
-            // the node limit on the SecurityManager may have changed so need 
to refresh.
-            nodeFactory.reset();
-            // Re-parse external schema location properties.
-            XMLSchemaLoader.processExternalHints(
-                fExternalSchemas,
-                fExternalNoNamespaceSchema,
-                fLocationPairs,
-                fXSIErrorReporter.fErrorReporter);
-            return;
+           // NO OP
         }
         
         // pass the component manager to the factory..



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to