test_filter will never match them anyway.
switch ( f->f_choice ) {
case SLAPD_FILTER_COMPUTED:
switch( f->f_result ) {
+ case SLAPD_COMPARE_UNDEFINED:
+ /* This technically is not the same as FALSE, but it
+ * certainly will produce no matches.
+ */
+ /* FALLTHRU */
case LDAP_COMPARE_FALSE:
BDB_IDL_ZERO( ids );
break;
struct bdb_info *bdb = (struct bdb_info *)op->o_bd->be_private;
BDB_IDL_ALL( bdb, ids );
} break;
- case SLAPD_COMPARE_UNDEFINED:
+ case LDAP_SUCCESS:
+ /* this is a pre-computed scope, leave it alone */
break;
}
break;
#endif
for ( f = flist; f != NULL; f = f->f_next ) {
- /* Ignore undefined filters */
- if ( f->f_choice == SLAPD_FILTER_COMPUTED &&
- f->f_result == SLAPD_COMPARE_UNDEFINED ) {
- continue;
- }
rc = bdb_filter_candidates( op, f, save, tmp,
save+BDB_IDL_UM_SIZE );
f.f_and = &nf;
/* Dummy; we compute scope separately now */
nf.f_choice = SLAPD_FILTER_COMPUTED;
- nf.f_result = SLAPD_COMPARE_UNDEFINED;
+ nf.f_result = LDAP_SUCCESS;
nf.f_next = xf.f_or == op->oq_search.rs_filter
? op->oq_search.rs_filter : &xf ;
/* Filter depth increased again, adding dummy clause */
switch( f->f_result ) {
case SLAPD_COMPARE_UNDEFINED:
/* This technically is not the same as FALSE, but it
- * certainly will produce no matches. list_candidates
- * will take care of ignoring this filter.
+ * certainly will produce no matches.
*/
/* FALLTHRU */
case LDAP_COMPARE_FALSE:
idl = NULL;
for ( f = flist; f != NULL; f = f->f_next ) {
- if ( f->f_choice == SLAPD_FILTER_COMPUTED &&
- f->f_result == SLAPD_COMPARE_UNDEFINED ) {
- continue;
- }
if ( (tmp = filter_candidates( op, f )) == NULL &&
ftype == LDAP_FILTER_AND ) {
#ifdef NEW_LOGGING