directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r1141876 - in /directory/apacheds/branches/apacheds-no-reverse-index: jdbm-partition/src/test/java/org/apache/directory/server/core/partition/impl/btree/jdbm/ xdbm-partition/src/main/java/org/apache/directory/server/xdbm/
Date Fri, 01 Jul 2011 08:54:38 GMT
Author: elecharny
Date: Fri Jul  1 08:54:37 2011
New Revision: 1141876

URL: http://svn.apache.org/viewvc?rev=1141876&view=rev
Log:
o Another fix for the RDN index

Modified:
    directory/apacheds/branches/apacheds-no-reverse-index/jdbm-partition/src/test/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmStoreTest.java
    directory/apacheds/branches/apacheds-no-reverse-index/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/AbstractStore.java

Modified: directory/apacheds/branches/apacheds-no-reverse-index/jdbm-partition/src/test/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmStoreTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-no-reverse-index/jdbm-partition/src/test/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmStoreTest.java?rev=1141876&r1=1141875&r2=1141876&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-no-reverse-index/jdbm-partition/src/test/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmStoreTest.java
(original)
+++ directory/apacheds/branches/apacheds-no-reverse-index/jdbm-partition/src/test/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmStoreTest.java
Fri Jul  1 08:54:37 2011
@@ -478,7 +478,7 @@ public class JdbmStoreTest
     }
 
 
-    @Test( expected=LdapContextNotEmptyException.class )
+    @Test
     public void testFreshStore() throws Exception
     {
         Dn dn = new Dn( schemaManager, "o=Good Times Co." );

Modified: directory/apacheds/branches/apacheds-no-reverse-index/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/AbstractStore.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-no-reverse-index/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/AbstractStore.java?rev=1141876&r1=1141875&r2=1141876&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-no-reverse-index/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/AbstractStore.java
(original)
+++ directory/apacheds/branches/apacheds-no-reverse-index/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/AbstractStore.java
Fri Jul  1 08:54:37 2011
@@ -1194,7 +1194,13 @@ public abstract class AbstractStore<E, I
         // Compute some ID references
         ID rootId = getRootId();
         List<ID> parentIds = getParentIds( entryDn );
-        ID parentId = parentIds.get( parentIds.size() - 1 );
+        
+        ID parentId = rootId;
+        
+        if ( parentIds.size() > 2 )
+        {
+            parentId = parentIds.get( parentIds.size() - 1 );
+        }
 
         // Drop the RDN
         ParentIdAndRdn<ID> key = new ParentIdAndRdn<ID>( parentId, entry.getDn().getRdn()
);



Mime
View raw message