- /*
- * if attr is objectClass, try to remap the value
- */
- if ( op->oq_compare.rs_ava->aa_desc == slap_schema.si_ad_objectClass ) {
- ldap_back_map( &li->targets[ i ]->rwmap.rwm_oc,
- &op->oq_compare.rs_ava->aa_value,
- &mapped_value, BACKLDAP_MAP );
-
- if ( mapped_value.bv_val == NULL || mapped_value.bv_val[0] == '\0' ) {
- continue;
- }
- /*
- * else try to remap the attribute
- */
- } else {
- ldap_back_map( &li->targets[ i ]->rwmap.rwm_at,
- &op->oq_compare.rs_ava->aa_desc->ad_cname,
- &mapped_attr, BACKLDAP_MAP );
- if ( mapped_attr.bv_val == NULL || mapped_attr.bv_val[0] == '\0' ) {
- continue;
- }
- }
-
- /*
- * the compare op is spawned across the targets and the first
- * that returns determines the result; a constraint on unicity
- * of the result ought to be enforced
- */
- msgid[ i ] = ldap_compare( lc->conns[ i ].ld, mdn.bv_val,
- mapped_attr.bv_val, mapped_value.bv_val );
- if ( mdn.bv_val != op->o_req_dn.bv_val ) {
- free( mdn.bv_val );
- mdn.bv_val = NULL;
- }
- if ( mapped_attr.bv_val != op->oq_compare.rs_ava->aa_desc->ad_cname.bv_val ) {
- free( mapped_attr.bv_val );
- }
- if ( mapped_value.bv_val != op->oq_compare.rs_ava->aa_value.bv_val ) {
- free( mapped_value.bv_val );
- }
-
- if ( msgid[ i ] == -1 ) {
- continue;
- }