You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by pa...@apache.org on 2007/04/03 17:57:58 UTC

svn commit: r525190 - /directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/subtree/BaseSubtreeSpecification.java

Author: pamarcelot
Date: Tue Apr  3 08:57:57 2007
New Revision: 525190

URL: http://svn.apache.org/viewvc?view=rev&rev=525190
Log:
Fixed a bug that could caused a malformed expression in the case where a BaseSubtreeSpecification has both chopBefore AND chopAfter values (a ',' was missing between the chopBefore and the chopAfter values in the printToBuffer() method).

Modified:
    directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/subtree/BaseSubtreeSpecification.java

Modified: directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/subtree/BaseSubtreeSpecification.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/subtree/BaseSubtreeSpecification.java?view=diff&rev=525190&r1=525189&r2=525190
==============================================================================
--- directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/subtree/BaseSubtreeSpecification.java (original)
+++ directory/shared/trunk/ldap/src/main/java/org/apache/directory/shared/ldap/subtree/BaseSubtreeSpecification.java Tue Apr  3 08:57:57 2007
@@ -276,7 +276,8 @@
             buffer.append( ',' );
         }
         
-        if(!chopBefore.isEmpty() || !chopAfter.isEmpty()) {
+        if ( !chopBefore.isEmpty() || !chopAfter.isEmpty() ) 
+        {
             buffer.append( ' ' );
             buffer.append( "specificExclusions" );
             buffer.append( ' ' );
@@ -298,6 +299,12 @@
                     buffer.append( ',' );
                     buffer.append( ' ' );
                 }
+            }
+            
+            if ( !chopBefore.isEmpty() && !chopAfter.isEmpty() )
+            {
+                buffer.append( ',' );
+                buffer.append( ' ' );
             }
             
             for ( Iterator it = chopAfter.iterator(); it.hasNext(); )