From: Pierangelo Masarati Date: Thu, 16 Feb 2006 23:37:42 +0000 (+0000) Subject: be conservative in reading subtree-exclude X-Git-Tag: OPENLDAP_REL_ENG_2_4_BP~175 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=41f963644c1d41d56ecb7dfbb804d93e1d252048;p=openldap be conservative in reading subtree-exclude --- diff --git a/servers/slapd/back-meta/config.c b/servers/slapd/back-meta/config.c index a977de33e5..cf26945dfe 100644 --- a/servers/slapd/back-meta/config.c +++ b/servers/slapd/back-meta/config.c @@ -338,9 +338,10 @@ meta_back_db_config( "subtree-exclude DN=\"%s\" " "is suffix of another subtree-exclude\n", fname, lineno, argv[ 1 ] ); - ber_memfree( mi->mi_targets[ i ].mt_subtree_exclude[ j ].bv_val ); - mi->mi_targets[ i ].mt_subtree_exclude[ j ] = ndn; - return( 0 ); + /* reject, because it might be superior + * to more than one subtree-exclude */ + ber_memfree( ndn.bv_val ); + return( 1 ); } else if ( dnIsSuffix( &ndn, &mi->mi_targets[ i ].mt_subtree_exclude[ j ] ) ) { Debug( LDAP_DEBUG_ANY, "%s: line %d: "