]> git.sur5r.net Git - openldap/commitdiff
Basic donUseCopy implementation
authorKurt Zeilenga <kurt@openldap.org>
Tue, 22 Aug 2006 20:29:14 +0000 (20:29 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Tue, 22 Aug 2006 20:29:14 +0000 (20:29 +0000)
servers/slapd/compare.c

index 55dca8040574af004bda49dc380f1cea6ba38043..f69c162527bc7970e493eb3cde24e13f8128d558 100644 (file)
@@ -243,7 +243,13 @@ fe_op_compare( Operation *op, SlapReply *rs )
                ava.aa_desc->ad_cname.bv_val, 0, 0 );
 
        op->orc_ava = &ava;
-       if ( ava.aa_desc == slap_schema.si_ad_entryDN ) {
+
+       if ( SLAP_SHADOW(op->o_bd) && get_dontUseCopy(op) ) {
+               /* don't use shadow copy */
+               send_ldap_error( op, rs, LDAP_UNWILLING_TO_PERFORM,
+                       "copy not used" );
+
+       } else if ( ava.aa_desc == slap_schema.si_ad_entryDN ) {
                send_ldap_error( op, rs, LDAP_UNWILLING_TO_PERFORM,
                        "entryDN compare not supported" );