Add SLAP_DBFLAG_OVERLAY

This commit is contained in:
Howard Chu 2004-11-27 11:45:54 +00:00
parent b4eceddb52
commit d3ced75fe7
3 changed files with 6 additions and 1 deletions

View File

@ -1535,7 +1535,8 @@ int backend_operational(
/* Let the overlays have a chance at this */
be_orig = op->o_bd;
op->o_bd = select_backend( be_orig->be_nsuffix, 0, 0 );
if ( SLAP_ISOVERLAY( be_orig ))
op->o_bd = select_backend( be_orig->be_nsuffix, 0, 0 );
if (( SLAP_OPATTRS( rs->sr_attr_flags ) || op->ors_attrs ) &&
op->o_bd && op->o_bd->be_operational != NULL )

View File

@ -178,6 +178,7 @@ over_back_response ( Operation *op, SlapReply *rs )
int rc = SLAP_CB_CONTINUE;
BackendDB *be = op->o_bd, db = *op->o_bd;
db.be_flags |= SLAP_DBFLAG_OVERLAY;
op->o_bd = &db;
for (; on; on=on->on_next ) {
if ( on->on_response ) {
@ -241,6 +242,7 @@ over_op_func(
slap_callback cb = {NULL, over_back_response, NULL, NULL};
int rc = SLAP_CB_CONTINUE;
db.be_flags |= SLAP_DBFLAG_OVERLAY;
op->o_bd = &db;
cb.sc_next = op->o_callback;
cb.sc_private = oi;

View File

@ -1565,6 +1565,7 @@ struct slap_backend_db {
#define SLAP_DBFLAG_GLUE_INSTANCE 0x0010U /* a glue backend */
#define SLAP_DBFLAG_GLUE_SUBORDINATE 0x0020U /* child of a glue hierarchy */
#define SLAP_DBFLAG_GLUE_LINKED 0x0040U /* child is connected to parent */
#define SLAP_DBFLAG_OVERLAY 0x0080U /* this db struct is an overlay */
#define SLAP_DBFLAG_SHADOW 0x8000U /* a shadow */
#define SLAP_DBFLAG_SYNC_SHADOW 0x1000U /* a sync shadow */
#define SLAP_DBFLAG_SLURP_SHADOW 0x2000U /* a slurp shadow */
@ -1572,6 +1573,7 @@ struct slap_backend_db {
#define SLAP_DBFLAGS(be) ((be)->be_flags)
#define SLAP_NOLASTMOD(be) (SLAP_DBFLAGS(be) & SLAP_DBFLAG_NOLASTMOD)
#define SLAP_LASTMOD(be) (!SLAP_NOLASTMOD(be))
#define SLAP_ISOVERLAY(be) (SLAP_DBFLAGS(be) & SLAP_DBFLAG_OVERLAY)
#define SLAP_NO_SCHEMA_CHECK(be) \
(SLAP_DBFLAGS(be) & SLAP_DBFLAG_NO_SCHEMA_CHECK)
#define SLAP_GLUE_INSTANCE(be) \