#include "slap.h"
#include "ldap_pvt.h"
+#include "ldap_pvt_uc.h"
int schema_init_done = 0;
static int
objectClassMatch(
int *matchp,
- unsigned flags,
+ slap_mask_t flags,
Syntax *syntax,
MatchingRule *mr,
struct berval *value,
static int
structuralObjectClassMatch(
int *matchp,
- unsigned flags,
+ slap_mask_t flags,
Syntax *syntax,
MatchingRule *mr,
struct berval *value,
{ NULL, NULL, NULL, NULL, 0 }
};
+static AttributeType slap_at_undefined = {
+ "UNDEFINED", /* cname */
+ { "1.1.1", NULL, NULL, 1, NULL,
+ NULL, NULL, NULL, NULL,
+ 0, 0, 0, 1, 3 },
+ NULL, /* sup */
+ NULL, /* subtypes */
+ NULL, NULL, NULL, NULL, /* matching rules */
+ NULL, /* syntax (this may need to be defined) */
+ NULL /* next */
+};
int
schema_prep( void )
/* we should only be called once after schema_init() was called */
assert( schema_init_done == 1 );
+ ucdata_load( global_ucdata_path ? global_ucdata_path :
+ SLAPD_DEFAULT_UCDATA, UCDATA_CASE|UCDATA_CTYPE|UCDATA_NUM );
+
for( i=0; oc_map[i].ssom_name; i++ ) {
ObjectClass ** ocp = (ObjectClass **)
&(((char *) &slap_schema)[oc_map[i].ssom_offset]);
}
}
+ slap_at_undefined.sat_syntax = syn_find( SLAPD_OCTETSTRING_SYNTAX );
+ if( slap_at_undefined.sat_syntax == NULL ) {
+ fprintf( stderr,
+ "No octetString syntax \"" SLAPD_OCTETSTRING_SYNTAX "\"\n" );
+ return LDAP_INVALID_SYNTAX;
+ }
+ slap_schema.si_at_undefined = &slap_at_undefined;
+
++schema_init_done;
return LDAP_SUCCESS;
}