Commit d30264a2 authored by Kurt Zeilenga's avatar Kurt Zeilenga
Browse files

Trim unimplemented syntaxes and matching rules from subschema subentry

parent 66818be6
......@@ -226,6 +226,11 @@ int mr_schema_info( Entry *e )
vals[1] = NULL;
for ( mr = mr_list; mr; mr = mr->smr_next ) {
if ( ! mr->smr_match ) {
/* skip rules without matching functions */
continue;
}
val.bv_val = ldap_matchingrule2str( &mr->smr_mrule );
if ( val.bv_val == NULL ) {
......
......@@ -3662,7 +3662,6 @@ struct syntax_defs_rec {
#endif
};
#define X_HIDE "X-HIDE 'TRUE' "
#define X_BINARY "X-BINARY-TRANSFER-REQUIRED 'TRUE' "
#define X_NOT_H_R "X-NOT-HUMAN-READABLE 'TRUE' "
......@@ -3792,7 +3791,7 @@ struct syntax_defs_rec syntax_defs[] = {
0, NULL, NULL, NULL},
/* OpenLDAP Void Syntax */
{"( 1.3.6.1.4.1.4203.1.1.1 DESC 'OpenLDAP void' " X_HIDE ")" ,
{"( 1.3.6.1.4.1.4203.1.1.1 DESC 'OpenLDAP void' )" ,
SLAP_SYNTAX_HIDE, inValidate, NULL, NULL},
{NULL, 0, NULL, NULL, NULL}
};
......
......@@ -183,6 +183,15 @@ syn_schema_info( Entry *e )
vals[1] = NULL;
for ( syn = syn_list; syn; syn = syn->ssyn_next ) {
if ( ! syn->ssyn_validate ) {
/* skip syntaxes without validators */
continue;
}
if ( syn->ssyn_flags & SLAP_SYNTAX_HIDE ) {
/* hide syntaxes */
continue;
}
val.bv_val = ldap_syntax2str( &syn->ssyn_syn );
if ( val.bv_val == NULL ) {
return -1;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment