]> git.sur5r.net Git - openldap/commitdiff
Fix bei_state access
authorHoward Chu <hyc@openldap.org>
Mon, 19 May 2008 16:19:59 +0000 (16:19 +0000)
committerHoward Chu <hyc@openldap.org>
Mon, 19 May 2008 16:19:59 +0000 (16:19 +0000)
http://www.openldap.org/lists/openldap-devel/200805/msg00073.html

servers/slapd/back-bdb/dn2id.c

index e23784c1a3e4cd1d3c2ab604c797395cd0447c33..7e72fc4a7941cc20855dc614da7f3287cda2e996 100644 (file)
@@ -1156,7 +1156,11 @@ gotit:
                                }
                                cx->depth--;
                                cx->op->o_tmpfree( save, cx->op->o_tmpmemctx );
-                               if ( nokids ) ei->bei_state |= CACHE_ENTRY_NO_GRANDKIDS;
+                               if ( nokids ) {
+                                       bdb_cache_entryinfo_lock( ei );
+                                       ei->bei_state |= CACHE_ENTRY_NO_GRANDKIDS;
+                                       bdb_cache_entryinfo_unlock( ei );
+                               }
                        }
                        /* Make sure caller knows it had kids! */
                        cx->tmp[0]=1;