From c9562fa8fbf7f66ad62f691705784f09ddb256fc Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Tue, 29 Aug 2006 02:02:12 +0000 Subject: [PATCH] Hide config schema if !LDAP_DEVEL --- servers/slapd/config.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/servers/slapd/config.c b/servers/slapd/config.c index e467df82e3..a9bacd0a62 100644 --- a/servers/slapd/config.c +++ b/servers/slapd/config.c @@ -509,6 +509,10 @@ init_config_attrs(ConfigTable *ct) { fprintf( stderr, "init_config_attrs: AttributeType \"%s\": %s\n", ct[i].attribute, err ); return code; + } else { +#ifndef LDAP_DEVEL + ct[i].ad->ad_type->sat_flags |= SLAP_AT_HIDE; +#endif } } @@ -539,10 +543,14 @@ init_config_ocs( ConfigOCs *ocs ) { return code; } ocs[i].co_oc = oc_find(oc->oc_names[0]); - if ( code ) + if ( code ) { ldap_objectclass_free(oc); - else + } else { ldap_memfree(oc); +#ifndef LDAP_DEVEL + ocs[i].co_oc->soc_flags |= SLAP_OC_HIDE; +#endif + } } return 0; } -- 2.39.5