From: Howard Chu Date: Wed, 27 Oct 2004 14:01:12 +0000 (+0000) Subject: ITS#3358 - make bdb_cache_lru_add skip entries that are being deleted X-Git-Tag: OPENLDAP_REL_ENG_2_3_0ALPHA~400 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=e7ec96fc6db7898a50e6b18698656012c7220ff7;p=openldap ITS#3358 - make bdb_cache_lru_add skip entries that are being deleted --- diff --git a/servers/slapd/back-bdb/cache.c b/servers/slapd/back-bdb/cache.c index bea7cf63b3..5c6b3375e9 100644 --- a/servers/slapd/back-bdb/cache.c +++ b/servers/slapd/back-bdb/cache.c @@ -527,9 +527,10 @@ bdb_cache_lru_add( lockp ) == 0 ) { /* If there's no entry, or this node is in * the process of linking into the cache, - * skip it. + * or this node is being deleted, skip it. */ - if ( !elru->bei_e || (elru->bei_state & CACHE_ENTRY_NOT_LINKED) ) { + if ( !elru->bei_e || (elru->bei_state & + ( CACHE_ENTRY_NOT_LINKED | CACHE_ENTRY_DELETED ))) { bdb_cache_entry_db_unlock( bdb->bi_dbenv, lockp ); continue; }