case LDAP_SCOPE_ONELEVEL:
case LDAP_SCOPE_SUBTREE:
+#ifdef LDAP_SCOPE_SUBORDINATE
case LDAP_SCOPE_SUBORDINATE: /* FIXME */
+#endif
op->o_callback = &cb;
rs->sr_err = gs.err = LDAP_UNWILLING_TO_PERFORM;
scope0 = op->ors_scope;
* check for abandon
*/
if (op->o_abandon) {
- op->ors_scope = scope0;
- op->ors_slimit = slimit0;
- op->ors_tlimit = tlimit0;
- op->o_req_dn = dn;
- op->o_req_ndn = ndn;
- goto done;
+ goto end_of_loop;
}
op->o_bd = gi->n[i].be;
break;
}
- op->o_callback = cb.sc_next;
- rs->sr_err = gs.err;
- rs->sr_matched = gs.matched;
- rs->sr_ref = gs.refs;
+ if ( !op->o_abandon ) {
+ op->o_callback = cb.sc_next;
+ rs->sr_err = gs.err;
+ rs->sr_matched = gs.matched;
+ rs->sr_ref = gs.refs;
- send_ldap_result( op, rs );
+ send_ldap_result( op, rs );
+ }
-done:
op->o_bd = b0;
if (gs.matched)
free (gs.matched);
if (SLAP_GLUE_SUBORDINATE ( b1 ) ) {
/* The last database cannot be a subordinate of noone */
if (i == nBackendDB - 1) {
- b1->be_flags ^= SLAP_BFLAG_GLUE_SUBORDINATE;
+ SLAP_DBFLAGS(b1) ^= SLAP_DBFLAG_GLUE_SUBORDINATE;
}
continue;
}
continue;
}
cont--;
- be->be_flags |= SLAP_BFLAG_GLUE_LINKED;
+ SLAP_DBFLAGS(be) |= SLAP_DBFLAG_GLUE_LINKED;
if (gi == NULL) {
/* We create a copy of the superior's be
* structure, pointing to all of its original
* is used whenever we have operations to pass
* down to the real database.
*/
- b1->be_flags |= SLAP_BFLAG_GLUE_INSTANCE;
+ SLAP_DBFLAGS(b1) |= SLAP_DBFLAG_GLUE_INSTANCE;
gi = (glueinfo *)ch_malloc(sizeof(glueinfo));
gi->nodes = 0;
gi->bd = *b1;