From 41f963644c1d41d56ecb7dfbb804d93e1d252048 Mon Sep 17 00:00:00 2001 From: Pierangelo Masarati Date: Thu, 16 Feb 2006 23:37:42 +0000 Subject: [PATCH] be conservative in reading subtree-exclude --- servers/slapd/back-meta/config.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) 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: " -- 2.39.5