static char *const err2text[] = {
"",
"Out of memory",
- "Objectclass not found",
- "Attribute type not found",
- "Duplicate objectclass",
- "Duplicate attributetype",
- "Duplicate syntax",
- "Duplicate matchingrule",
+ "ObjectClass not found",
+ "AttributeType not found",
+ "Duplicate objectClass",
+ "Duplicate attributeType",
+ "Duplicate ldapSyntax",
+ "Duplicate matchingRule",
"OID or name required",
- "Syntax or superior required",
- "Matchingrule not found",
+ "SYNTAX or SUPerior required",
+ "MatchingRule not found",
"Syntax not found",
"Syntax required"
};
for( namep = oc->oc_at_oids_must; *namep ; namep++ ) {
code = at_fake_if_needed( *namep );
if ( code ) {
- fprintf( stderr, "%s: line %d: %s %s\n",
+ fprintf( stderr, "%s: line %d: %s: \"%s\"\n",
fname, lineno, scherr2str(code), *namep);
exit( EXIT_FAILURE );
}
for( namep = oc->oc_at_oids_may; *namep; namep++ ) {
code = at_fake_if_needed( *namep );
if ( code ) {
- fprintf( stderr, "%s: line %d: %s %s\n",
+ fprintf( stderr, "%s: line %d: %s: \"%s\"\n",
fname, lineno, scherr2str(code), *namep);
exit( EXIT_FAILURE );
}
code = oc_add(oc,&err);
if ( code ) {
- fprintf( stderr, "%s: line %d: %s %s\n",
+ fprintf( stderr, "%s: line %d: %s: \"%s\"\n",
fname, lineno, scherr2str(code), err);
exit( EXIT_FAILURE );
}
const char *err;
char *oid = NULL;
- oc = ldap_str2objectclass(line,&code,&err);
+ oc = ldap_str2objectclass(line,&code,&err,LDAP_SCHEMA_ALLOW_ALL);
if ( !oc ) {
fprintf( stderr, "%s: line %d: %s before %s\n",
fname, lineno, ldap_scherr2str(code), err );
/* oc->oc_oid == NULL will be an error someday */
code = oc_add(oc,&err);
if ( code ) {
- fprintf( stderr, "%s: line %d: %s %s\n",
+ fprintf( stderr, "%s: line %d: %s: \"%s\"\n",
fname, lineno, scherr2str(code), err);
exit( EXIT_FAILURE );
}
break;
}
}
- at = ldap_str2attributetype(line,&code,&err);
+ at = ldap_str2attributetype(line,&code,&err,LDAP_SCHEMA_ALLOW_ALL);
if ( !at ) {
fprintf( stderr, "%s: line %d: %s before %s\n",
fname, lineno, ldap_scherr2str(code), err );
}
code = at_add(at,&err);
if ( code ) {
- fprintf( stderr, "%s: line %d: %s %s\n",
+ fprintf( stderr, "%s: line %d: %s: \"%s\"\n",
fname, lineno, scherr2str(code), err);
exit( EXIT_FAILURE );
}