]> git.sur5r.net Git - openldap/commitdiff
fix objectClass inheritance deletion (ITS#5517, ITS#5963)
authorPierangelo Masarati <ando@openldap.org>
Sun, 22 Feb 2009 23:32:00 +0000 (23:32 +0000)
committerPierangelo Masarati <ando@openldap.org>
Sun, 22 Feb 2009 23:32:00 +0000 (23:32 +0000)
servers/slapd/mods.c

index 1ad15f8906997ed3068939a25d4a1237cc16e0c6..c8d8b9c9e29a27b0116a7768466c84d75b167b58 100644 (file)
@@ -263,13 +263,18 @@ modify_delete_vindex(
                goto return_result;
        }
 
+       if ( a->a_desc == slap_schema.si_ad_objectClass ) {
+               /* Needed by ITS#5517,ITS#5963 */
+               flags = SLAP_MR_EQUALITY | SLAP_MR_VALUE_OF_ATTRIBUTE_SYNTAX;
+
+       } else {
+               flags = SLAP_MR_EQUALITY | SLAP_MR_VALUE_OF_ASSERTION_SYNTAX;
+       }
        if ( mod->sm_nvalues ) {
-               flags = SLAP_MR_EQUALITY | SLAP_MR_VALUE_OF_ASSERTION_SYNTAX
-                       | SLAP_MR_ASSERTED_VALUE_NORMALIZED_MATCH
+               flags |= SLAP_MR_ASSERTED_VALUE_NORMALIZED_MATCH
                        | SLAP_MR_ATTRIBUTE_VALUE_NORMALIZED_MATCH;
                cvals = mod->sm_nvalues;
        } else {
-               flags = SLAP_MR_EQUALITY | SLAP_MR_VALUE_OF_ASSERTION_SYNTAX;
                cvals = mod->sm_values;
        }