directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r495114 - /directory/trunks/apacheds/schema-registries/src/main/java/org/apache/directory/server/schema/registries/DefaultAttributeTypeRegistry.java
Date Thu, 11 Jan 2007 04:56:19 GMT
Author: akarasulu
Date: Wed Jan 10 20:56:18 2007
New Revision: 495114

URL: http://svn.apache.org/viewvc?view=rev&rev=495114
Log:
fixed NPE causing bug

Modified:
    directory/trunks/apacheds/schema-registries/src/main/java/org/apache/directory/server/schema/registries/DefaultAttributeTypeRegistry.java

Modified: directory/trunks/apacheds/schema-registries/src/main/java/org/apache/directory/server/schema/registries/DefaultAttributeTypeRegistry.java
URL: http://svn.apache.org/viewvc/directory/trunks/apacheds/schema-registries/src/main/java/org/apache/directory/server/schema/registries/DefaultAttributeTypeRegistry.java?view=diff&rev=495114&r1=495113&r2=495114
==============================================================================
--- directory/trunks/apacheds/schema-registries/src/main/java/org/apache/directory/server/schema/registries/DefaultAttributeTypeRegistry.java
(original)
+++ directory/trunks/apacheds/schema-registries/src/main/java/org/apache/directory/server/schema/registries/DefaultAttributeTypeRegistry.java
Wed Jan 10 20:56:18 2007
@@ -129,7 +129,12 @@
     protected void onRegisterAddToAncestorDescendants( AttributeType newType, AttributeType
ancestor ) 
         throws NamingException
     {
-        if ( ancestor == null || ancestor.getName().equals( "top" ) )
+        if ( ancestor == null )
+        {
+            return;
+        }
+        
+        if ( ancestor.getName() != null && ancestor.getName().equals( "top" ) )
         {
             return;
         }



Mime
View raw message