]> git.sur5r.net Git - openldap/commitdiff
much better fix for ITS#2196 (dnattr without sat_equality is bounced at config)
authorPierangelo Masarati <ando@openldap.org>
Mon, 25 Nov 2002 18:37:04 +0000 (18:37 +0000)
committerPierangelo Masarati <ando@openldap.org>
Mon, 25 Nov 2002 18:37:04 +0000 (18:37 +0000)
servers/slapd/aclparse.c
servers/slapd/value.c

index 80ffa377bff833f7edb82b533cde964a7cec5bd1..d420a0b4c72d5f4c34023b1c6d5d9fe699e99750 100644 (file)
@@ -464,6 +464,15 @@ parse_acl(
                                                acl_usage();
                                        }
 
+                                       if( b->a_dn_at->ad_type->sat_equality == NULL )
+                                       {
+                                               fprintf( stderr,
+                                                       "%s: line %d: dnattr \"%s\": "
+                                                       "inappropriate matching (no EQUALITY)\n",
+                                                       fname, lineno, right );
+                                               acl_usage();
+                                       }
+
                                        continue;
                                }
 
index 9ed1ad969f384ca3e8441641c1bbeb0a6ba80348..a232d066e98c4c9ae3346bb6fda8ae57bbd8741c 100644 (file)
@@ -324,10 +324,9 @@ value_match(
        struct berval nv1 = { 0, NULL };
        struct berval nv2 = { 0, NULL };
 
-       /*
-        * FIXME: mr should NOT be NULL ...
-        */
-       if( !mr || !mr->smr_match ) {
+       assert( mr != NULL );
+
+       if( !mr->smr_match ) {
                return LDAP_INAPPROPRIATE_MATCHING;
        }