From: Howard Chu Date: Tue, 29 Apr 2008 21:44:47 +0000 (+0000) Subject: Fix prev cache.c commit X-Git-Tag: LOCKER_IDS~194 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=9b516293b9b107cee50568a5b4670fbde6177dba;p=openldap Fix prev cache.c commit --- diff --git a/servers/slapd/back-bdb/cache.c b/servers/slapd/back-bdb/cache.c index c778d81d28..edf73ab28c 100644 --- a/servers/slapd/back-bdb/cache.c +++ b/servers/slapd/back-bdb/cache.c @@ -1292,7 +1292,7 @@ bdb_cache_delete_cleanup( Cache *cache, EntryInfo *ei ) { - bdb_cache_entryinfo_lock( ei ); + /* Enter with ei locked */ if ( ei->bei_e ) { ei->bei_e->e_private = NULL; diff --git a/servers/slapd/back-bdb/delete.c b/servers/slapd/back-bdb/delete.c index dfa50bed0a..5008be4344 100644 --- a/servers/slapd/back-bdb/delete.c +++ b/servers/slapd/back-bdb/delete.c @@ -572,6 +572,7 @@ return_results: if( e != NULL ) { if ( rs->sr_err == LDAP_SUCCESS ) { /* Free the EntryInfo and the Entry */ + bdb_cache_entryinfo_lock( BEI(e) ); bdb_cache_delete_cleanup( &bdb->bi_cache, BEI(e) ); } else { bdb_unlocked_cache_return_entry_w(&bdb->bi_cache, e);