changeset 18891:be38bcc1d0f3

8020430: NullPointerException in xml sqe nightly result on 2013-07-12 Reviewed-by: chegar, lancea
author joehw
date Fri, 12 Jul 2013 11:12:40 -0700
parents 25bdeca3173b
children 8c0ce47b4b82
files jaxp/src/com/sun/org/apache/xerces/internal/impl/PropertyManager.java
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/jaxp/src/com/sun/org/apache/xerces/internal/impl/PropertyManager.java	Tue Jul 09 16:34:52 2013 -0700
+++ b/jaxp/src/com/sun/org/apache/xerces/internal/impl/PropertyManager.java	Fri Jul 12 11:12:40 2013 -0700
@@ -142,7 +142,7 @@
      */
     public boolean containsProperty(String property){
         return supportedProps.containsKey(property) ||
-                fSecurityPropertyMgr.getIndex(property) > -1 ;
+                (fSecurityPropertyMgr!=null && fSecurityPropertyMgr.getIndex(property) > -1) ;
     }
 
     public Object getProperty(String property){
@@ -169,7 +169,7 @@
             supportedProps.put( Constants.XERCES_PROPERTY_PREFIX + Constants.STAX_ENTITY_RESOLVER_PROPERTY , new StaxEntityResolverWrapper((XMLResolver)value)) ;
         }
 
-        int index = fSecurityPropertyMgr.getIndex(property);
+        int index = (fSecurityPropertyMgr != null) ? fSecurityPropertyMgr.getIndex(property) : -1;
         if (index > -1) {
             fSecurityPropertyMgr.setValue(index,
                     XMLSecurityPropertyManager.State.APIPROPERTY, (String)value);