From 49708e1bd5bba2010bd1bf0e021c636abfa54e5c Mon Sep 17 00:00:00 2001 From: Kurt Zeilenga Date: Tue, 22 Aug 2006 20:29:14 +0000 Subject: [PATCH] Basic donUseCopy implementation --- servers/slapd/compare.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/servers/slapd/compare.c b/servers/slapd/compare.c index 55dca80405..f69c162527 100644 --- a/servers/slapd/compare.c +++ b/servers/slapd/compare.c @@ -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" ); -- 2.39.5