]> git.sur5r.net Git - openldap/blobdiff - servers/slapd/value.c
cleanup
[openldap] / servers / slapd / value.c
index c05c1a09750c51f87c3c3f07f93a0103d9afc3ee..bf8077c7c68bcec966285e3ce83c93eb772b0fbb 100644 (file)
@@ -1,8 +1,28 @@
 /* value.c - routines for dealing with values */
 /* $OpenLDAP$ */
+/* This work is part of OpenLDAP Software <http://www.openldap.org/>.
+ *
+ * Copyright 1998-2004 The OpenLDAP Foundation.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted only as authorized by the OpenLDAP
+ * Public License.
+ *
+ * A copy of this license is available in the file LICENSE in the
+ * top-level directory of the distribution or, alternatively, at
+ * <http://www.OpenLDAP.org/license.html>.
+ */
 /*
- * Copyright 1998-2003 The OpenLDAP Foundation, All Rights Reserved.
- * COPYING RESTRICTIONS APPLY, see COPYRIGHT file
+ * Copyright (c) 1995 Regents of the University of Michigan.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms are permitted
+ * provided that this notice is preserved and that due credit is given
+ * to the University of Michigan at Ann Arbor. The name of the University
+ * may not be used to endorse or promote products derived from this
+ * software without specific prior written permission. This software
+ * is provided ``as is'' without express or implied warranty.
  */
 
 #include "portable.h"
@@ -163,7 +183,8 @@ int asserted_value_validate_normalize(
        }
 
        if( mr->smr_normalize ) {
-               rc = (mr->smr_normalize)( usage,
+               rc = (mr->smr_normalize)(
+                       usage|SLAP_MR_VALUE_OF_ASSERTION_SYNTAX,
                        ad ? ad->ad_type->sat_syntax : NULL,
                        mr, in, out, ctx );
 
@@ -205,7 +226,6 @@ value_match(
                return LDAP_INAPPROPRIATE_MATCHING;
        }
 
-
        rc = (mr->smr_match)( match, flags,
                ad->ad_type->sat_syntax,
                mr,
@@ -239,7 +259,7 @@ int value_find_ex(
                mr->smr_normalize )
        {
                rc = (mr->smr_normalize)(
-                       flags & (SLAP_MR_TYPE_MASK|SLAP_MR_SUBTYPE_MASK),
+                       flags & (SLAP_MR_TYPE_MASK|SLAP_MR_SUBTYPE_MASK|SLAP_MR_VALUE_OF_SYNTAX),
                        ad ? ad->ad_type->sat_syntax : NULL,
                        mr, val, &nval, ctx );