mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-23 16:19:35 -05:00
Use the first empty slot in the open cache table, so scan doesn't (usu
ally) have to look through the entire table.
This commit is contained in:
parent
1ae21d00f1
commit
93a622d5e1
1 changed files with 2 additions and 1 deletions
|
|
@ -62,7 +62,8 @@ ldbm_cache_open(
|
|||
for ( i = 0; i < MAXDBCACHE; i++ ) {
|
||||
/* see if this slot is free */
|
||||
if ( li->li_dbcache[i].dbc_name == NULL) {
|
||||
empty = i;
|
||||
if (empty == MAXDBCACHE)
|
||||
empty = i;
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue