From 3c68fc1f14e4e0aae3922ee2e0c255f0c493ddc8 Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Thu, 24 Jun 2004 23:50:10 +0000 Subject: [PATCH] ITS#3201 fix conflict with BDB internal locks --- servers/slapd/back-bdb/back-bdb.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/servers/slapd/back-bdb/back-bdb.h b/servers/slapd/back-bdb/back-bdb.h index ebc4cd0c8a..e3846c9b9b 100644 --- a/servers/slapd/back-bdb/back-bdb.h +++ b/servers/slapd/back-bdb/back-bdb.h @@ -92,7 +92,13 @@ typedef struct bdb_entry_info { struct bdb_entry_info *bei_parent; ID bei_id; - int bei_state; + /* we use the bei_id as a lockobj, but we need to make the size != 4 + * to avoid conflicting with BDB's internal locks. So add a byte here + * that is always zero. + */ + char bei_lockpad; + + short bei_state; #define CACHE_ENTRY_DELETED 1 #define CACHE_ENTRY_NO_KIDS 2 #define CACHE_ENTRY_NOT_LINKED 4 -- 2.39.5