From 74093d603cc2163e2c95433aa7a53c46d799d36e Mon Sep 17 00:00:00 2001 From: Noriko Hosoi Date: Thu, 20 Aug 2009 10:31:13 -0700 Subject: 509472 db2index all does not reindex all the db backends correctly The commit a26ba73fb5040383c27872997bc07ab0c2006459 made to fix the bug 509472 put the assertion at the wrong place. It should be applied just for the worker thread. --- ldap/servers/slapd/back-ldbm/import.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/ldap/servers/slapd/back-ldbm/import.c b/ldap/servers/slapd/back-ldbm/import.c index 8c334d43..76067391 100644 --- a/ldap/servers/slapd/back-ldbm/import.c +++ b/ldap/servers/slapd/back-ldbm/import.c @@ -106,11 +106,13 @@ FifoItem *import_fifo_fetch(ImportJob *job, ID id, int worker) return NULL; } if (fi->entry) { - if (worker && fi->bad) { - import_log_notice(job, "WARNING: bad entry: ID %d", id); - return NULL; + if (worker) { + if (fi->bad) { + import_log_notice(job, "WARNING: bad entry: ID %d", id); + return NULL; + } + PR_ASSERT(fi->entry->ep_refcnt > 0); } - PR_ASSERT(fi->entry->ep_refcnt > 0); } return fi; } -- cgit