}
acl_destroy( bd->be_acl, frontendDB->be_acl );
- assert( bd->be_replogfile == NULL );
+ if ( bd->be_replogfile != NULL ) {
+ free( bd->be_replogfile );
+ }
assert( bd->be_replica == NULL );
}
continue;
}
} else {
- b2 = be;
+ /* If any parts of the tree are glued, use the first
+ * match regardless of manageDSAit. Otherwise use the
+ * last match.
+ */
+ if( !( SLAP_DBFLAGS( be ) & ( SLAP_DBFLAG_GLUE_INSTANCE |
+ SLAP_DBFLAG_GLUE_SUBORDINATE )))
+ b2 = be;
}
return b2;
}
}
}
+ /* temporarily removed */
+#if 0
/* check should be generalized */
if( get_manageDIT(op) && !be_isroot(op)) {
rs->sr_text = "requires manager authorization";
rs->sr_err = LDAP_UNWILLING_TO_PERFORM;
}
+#endif
done:;
return rs->sr_err;
int rw,
Entry **e )
{
- int rc;
-
*e = NULL;
- if (op->o_bd == NULL) {
- rc = LDAP_NO_SUCH_OBJECT;
- } else if ( op->o_bd->be_fetch ) {
- rc = ( op->o_bd->be_fetch )( op, ndn,
- oc, at, rw, e );
- } else {
- rc = LDAP_UNWILLING_TO_PERFORM;
+ if ( op->o_bd == NULL ) {
+ return LDAP_NO_SUCH_OBJECT;
}
- return rc;
+
+ if ( op->o_bd->be_fetch ) {
+ return op->o_bd->be_fetch( op, ndn, oc, at, rw, e );
+ }
+
+ return LDAP_UNWILLING_TO_PERFORM;
}
int
be_orig = op->o_bd;
op->o_bd = frontendDB;
+#ifdef SLAP_OVERLAY_ACCESS
rc = frontendDB->be_group( op, target, gr_ndn,
op_ndn, group_oc, group_at );
+#else /* ! SLAP_OVERLAY_ACCESS */
+ rc = fe_acl_group( op, target, gr_ndn,
+ op_ndn, group_oc, group_at );
+#endif /* ! SLAP_OVERLAY_ACCESS */
op->o_bd = be_orig;
return rc;
be_orig = op->o_bd;
op->o_bd = frontendDB;
+#ifdef SLAP_OVERLAY_ACCESS
rc = frontendDB->be_attribute( op, target, edn,
entry_at, vals, access );
+#else /* !SLAP_OVERLAY_ACCESS */
+ rc = fe_acl_attribute( op, target, edn,
+ entry_at, vals, access );
+#endif /* !SLAP_OVERLAY_ACCESS */
op->o_bd = be_orig;
return rc;
/* Let the overlays have a chance at this */
be_orig = op->o_bd;
op->o_bd = select_backend( &op->o_req_ndn, 0, 0 );
- if ( op->o_bd != frontendDB &&
+ if ( !be_match( op->o_bd, frontendDB ) &&
( SLAP_OPATTRS( rs->sr_attr_flags ) || rs->sr_attrs ) &&
op->o_bd != NULL && op->o_bd->be_operational != NULL )
{