summaryrefslogtreecommitdiffstats
path: root/ldap/servers/slapd/entrywsi.c
diff options
context:
space:
mode:
Diffstat (limited to 'ldap/servers/slapd/entrywsi.c')
-rw-r--r--ldap/servers/slapd/entrywsi.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/ldap/servers/slapd/entrywsi.c b/ldap/servers/slapd/entrywsi.c
index 6b51ef1c..01c160c2 100644
--- a/ldap/servers/slapd/entrywsi.c
+++ b/ldap/servers/slapd/entrywsi.c
@@ -450,6 +450,10 @@ entry_add_present_values_wsi(Slapi_Entry *e, const char *type, struct berval **b
}
a_flags_orig = a->a_flags;
a->a_flags |= flags;
+ /* Check if the type of the to-be-added values has DN syntax or not. */
+ if (slapi_attr_is_dn_syntax_attr(a)) {
+ valuearray_normalize_value(valuestoadd);
+ }
if(urp)
{
/*
@@ -566,6 +570,11 @@ entry_delete_present_values_wsi(Slapi_Entry *e, const char *type, struct berval
/* delete some specific values */
Slapi_Value **valuestodelete= NULL;
valuearray_init_bervalarray(vals,&valuestodelete); /* JCM SLOW FUNCTION */
+ /* Check if the type of the to-be-deleted values has DN syntax
+ * or not. */
+ if (slapi_attr_is_dn_syntax_attr(a)) {
+ valuearray_normalize_value(valuestodelete);
+ }
if(urp)
{
Slapi_Value **valuesupdated= NULL;