mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-21 03:10:25 +08:00
Define MINIMUM_SEARCH_STACK_DEPTH=8, search_aliases needs at least this.
This commit is contained in:
parent
b2075ea932
commit
c0ee56c306
@ -65,6 +65,9 @@ LDAP_BEGIN_DECL
|
||||
/* The default search IDL stack cache depth */
|
||||
#define DEFAULT_SEARCH_STACK_DEPTH 16
|
||||
|
||||
/* The minimum we can function with */
|
||||
#define MINIMUM_SEARCH_STACK_DEPTH 8
|
||||
|
||||
/* for the IDL cache */
|
||||
#define SLAP_IDL_CACHE 1
|
||||
|
||||
|
@ -137,13 +137,20 @@ bdb_db_config(
|
||||
|
||||
/* depth of search stack cache in units of (IDL)s */
|
||||
} else if ( strcasecmp( argv[0], "searchstack" ) == 0 ) {
|
||||
if ( argc < 2 ) {
|
||||
fprintf( stderr,
|
||||
"%s: line %d: missing depth in \"searchstack <depth>\" line\n",
|
||||
fname, lineno );
|
||||
return( 1 );
|
||||
}
|
||||
bdb->bi_search_stack_depth = atoi( argv[1] );
|
||||
if ( argc < 2 ) {
|
||||
fprintf( stderr,
|
||||
"%s: line %d: missing depth in \"searchstack <depth>\" line\n",
|
||||
fname, lineno );
|
||||
return( 1 );
|
||||
}
|
||||
bdb->bi_search_stack_depth = atoi( argv[1] );
|
||||
if ( bdb->bi_search_stack_depth < MINIMUM_SEARCH_STACK_DEPTH ) {
|
||||
fprintf( stderr,
|
||||
"%s: line %d: depth %d too small, using %d\n",
|
||||
fname, lineno, bdb->bi_search_stack_depth,
|
||||
MINIMUM_SEARCH_STACK_DEPTH );
|
||||
bdb->bi_search_stack_depth = MINIMUM_SEARCH_STACK_DEPTH;
|
||||
}
|
||||
|
||||
#ifdef SLAP_IDL_CACHE
|
||||
/* size of the IDL cache in entries */
|
||||
|
Loading…
Reference in New Issue
Block a user