]> git.sur5r.net Git - openldap/blobdiff - servers/slapd/compare.c
Fixup bdb_entry_release now that entry_decode uses two memory blocks
[openldap] / servers / slapd / compare.c
index 2f4f03f6aed3f49bff2dbe7188fa4c08dec2c4fa..6c24393c00217d9100e7e5054a74207cd0913f13 100644 (file)
@@ -36,7 +36,6 @@ do_compare(
 )
 {
        Entry *entry = NULL;
-       Attribute       *a = NULL;
        char    *dn = NULL, *ndn=NULL;
        struct berval desc;
        struct berval value;
@@ -135,13 +134,13 @@ do_compare(
        rc = slap_bv2ad( &desc, &ava.aa_desc, &text );
        if( rc != LDAP_SUCCESS ) {
                send_ldap_result( conn, op, rc, NULL, text, NULL, NULL );
-               return rc;
+               goto cleanup;
        }
 
        rc = value_normalize( ava.aa_desc, SLAP_MR_EQUALITY, &value, &nvalue, &text );
        if( rc != LDAP_SUCCESS ) {
                send_ldap_result( conn, op, rc, NULL, text, NULL, NULL );
-               return rc;
+               goto cleanup;
        }
 
        ava.aa_value = nvalue;
@@ -303,10 +302,7 @@ static int compare_entry(
        {
                rc = LDAP_COMPARE_FALSE;
 
-               if ( value_find_ex( ava->aa_desc,
-                       SLAP_MR_VALUE_IS_IN_MR_SYNTAX,
-                       a->a_vals, ava->aa_value ) == 0 )
-               {
+               if ( value_find( ava->aa_desc, a->a_vals, ava->aa_value ) == 0 ) {
                        rc = LDAP_COMPARE_TRUE;
                        break;
                }