]> git.sur5r.net Git - openldap/commitdiff
fix substring_comp_candidates logic if intersection of candidates
authorKurt Zeilenga <kurt@openldap.org>
Fri, 16 Jul 1999 22:26:57 +0000 (22:26 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Fri, 16 Jul 1999 22:26:57 +0000 (22:26 +0000)
is ever empty.  See ITS#228.

servers/slapd/back-bdb2/filterindex.c
servers/slapd/back-ldbm/filterindex.c

index d5cc90d95fdcc3626fb587581593e1a7ce53aba4..32da1d85e7935f0d24e30b9948a4f5569ada0268 100644 (file)
@@ -345,6 +345,11 @@ substring_comp_candidates(
                        bdb2i_idl_free( tmp );
                        bdb2i_idl_free( tmp2 );
                }
+
+               /* break if no candidates */
+               if( idl == NULL ) {
+                       break;
+               }
        }
 
        Debug( LDAP_DEBUG_TRACE, "<= substring_comp_candidates %ld\n",
index 2c32d50d9fe734ee4000a84b8577dd7a62100f0b..65842a34633393bfd4ee3b5a92c3a134464b7a67 100644 (file)
@@ -345,6 +345,11 @@ substring_comp_candidates(
                        idl_free( tmp );
                        idl_free( tmp2 );
                }
+
+               /* break if no candidates */
+               if( idl == NULL ) {
+                       break;
+               }
        }
 
        Debug( LDAP_DEBUG_TRACE, "<= substring_comp_candidates %ld\n",