From: Kurt Zeilenga Date: Fri, 11 Jan 2002 18:26:17 +0000 (+0000) Subject: Add system schema flags to backends supporting system schema. X-Git-Tag: LDBM_PRE_GIANT_RWLOCK~186 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=f57057ee015ac48366de12b6dbb301e7ee18f1a6;p=openldap Add system schema flags to backends supporting system schema. --- diff --git a/servers/slapd/back-bdb/init.c b/servers/slapd/back-bdb/init.c index 72f872a39f..c6abc86dea 100644 --- a/servers/slapd/back-bdb/init.c +++ b/servers/slapd/back-bdb/init.c @@ -64,6 +64,11 @@ bdb_db_init( BackendDB *be ) "bdb_db_init: Initializing BDB database\n", 0, 0, 0 ); + /* indicate system schema supported */ + be->be_flags |= SLAP_BFLAG_ALIASES + | SLAP_BFLAG_REFERRALS + | SLAP_BFLAG_SUBENTRIES; + /* allocate backend-database-specific stuff */ bdb = (struct bdb_info *) ch_calloc( 1, sizeof(struct bdb_info) ); diff --git a/servers/slapd/back-ldbm/init.c b/servers/slapd/back-ldbm/init.c index 1afaf5c22e..1fe1335666 100644 --- a/servers/slapd/back-ldbm/init.c +++ b/servers/slapd/back-ldbm/init.c @@ -126,6 +126,9 @@ ldbm_back_db_init( { struct ldbminfo *li; + /* indicate system schema supported */ + be->be_flags |= SLAP_BFLAG_ALIASES|SLAP_BFLAG_REFERRALS; + /* allocate backend-database-specific stuff */ li = (struct ldbminfo *) ch_calloc( 1, sizeof(struct ldbminfo) ); diff --git a/servers/slapd/back-monitor/init.c b/servers/slapd/back-monitor/init.c index 415512901d..a2b91a1564 100644 --- a/servers/slapd/back-monitor/init.c +++ b/servers/slapd/back-monitor/init.c @@ -238,6 +238,9 @@ monitor_back_db_init( } be_monitor = be; + /* indicate system schema supported */ + be->be_flags |= SLAP_BFLAG_MONITOR; + ndn = NULL; dn.bv_val = SLAPD_MONITOR_DN; dn.bv_len = sizeof( SLAPD_MONITOR_DN ) - 1; diff --git a/servers/slapd/slap.h b/servers/slapd/slap.h index 1fb0207001..13752f9c6b 100644 --- a/servers/slapd/slap.h +++ b/servers/slapd/slap.h @@ -1025,13 +1025,13 @@ struct slap_backend_db { #define SLAP_BFLAG_ALIASES 0x0100U #define SLAP_BFLAG_REFERRALS 0x0200U #define SLAP_BFLAG_SUBENTRIES 0x0400U -#define SLAP_BFLAG_NOMONITOR 0x1000U +#define SLAP_BFLAG_MONITOR 0x1000U slap_mask_t be_flags; #define SLAP_LASTMOD(be) (!((be)->be_flags & SLAP_BFLAG_NOLASTMOD)) #define SLAP_ALIASES(be) ((be)->be_flags & SLAP_BFLAG_ALIASES) #define SLAP_REFERRALS(be) ((be)->be_flags & SLAP_BFLAG_REFERRALS) #define SLAP_SUBENTRIES(be) ((be)->be_flags & SLAP_BFLAG_SUBENTRIES) -#define SLAP_MONITOR(be) (!(be)->be_flags & SLAP_BFLAG_NOMONITOR)) +#define SLAP_MONITOR(be) ((be)->be_flags & SLAP_BFLAG_MONITOR) slap_mask_t be_restrictops; /* restriction operations */ #define SLAP_RESTRICT_OP_ADD 0x0001U