version 1.103.2.9, 2009/02/05 19:35:54
|
version 1.103.2.10, 2009/02/22 20:56:29
|
Line 1
|
Line 1
|
/* schema_check.c - routines to enforce schema definitions */ |
/* schema_check.c - routines to enforce schema definitions */ |
/* $OpenLDAP: pkg/ldap/servers/slapd/schema_check.c,v 1.103.2.8 2009/01/22 00:01:03 kurt Exp $ */ |
/* $OpenLDAP: pkg/ldap/servers/slapd/schema_check.c,v 1.103.2.9 2009/02/05 19:35:54 quanah Exp $ */ |
/* This work is part of OpenLDAP Software <http://www.openldap.org/>. |
/* This work is part of OpenLDAP Software <http://www.openldap.org/>. |
* |
* |
* Copyright 1998-2009 The OpenLDAP Foundation. |
* Copyright 1998-2009 The OpenLDAP Foundation. |
Line 881 entry_naming_check(
|
Line 881 entry_naming_check(
|
SLAP_MR_ATTRIBUTE_VALUE_NORMALIZED_MATCH, |
SLAP_MR_ATTRIBUTE_VALUE_NORMALIZED_MATCH, |
&ava->la_value, NULL, NULL ); |
&ava->la_value, NULL, NULL ); |
|
|
if( rc != 0 ) { |
if ( rc != 0 ) { |
switch( rc ) { |
switch( rc ) { |
case LDAP_INAPPROPRIATE_MATCHING: |
case LDAP_INAPPROPRIATE_MATCHING: |
snprintf( textbuf, textlen, |
snprintf( textbuf, textlen, |
Line 895 entry_naming_check(
|
Line 895 entry_naming_check(
|
break; |
break; |
case LDAP_NO_SUCH_ATTRIBUTE: |
case LDAP_NO_SUCH_ATTRIBUTE: |
if ( add_naming ) { |
if ( add_naming ) { |
add = 1; |
if ( is_at_single_value( desc->ad_type ) ) { |
rc = LDAP_SUCCESS; |
snprintf( textbuf, textlen, |
|
"value of single-valued naming attribute '%s' conflicts with value present in entry", |
|
ava->la_attr.bv_val ); |
|
|
|
} else { |
|
add = 1; |
|
rc = LDAP_SUCCESS; |
|
} |
|
|
} else { |
} else { |
snprintf( textbuf, textlen, |
snprintf( textbuf, textlen, |
"value of naming attribute '%s' is not present in entry", |
"value of naming attribute '%s' is not present in entry", |