This is an automated email from the git hooks/post-receive script.
lkrispen pushed a change to branch master
in repository 389-ds-base.
from 14e413a Issue 49043 - Add replica conflict test suite
new ec4a669 ticket 49551 - correctly handle subordinates and tombstone
numsubordinates
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "adds" were already present in the repository and have only
been added to this reference.
Summary of changes:
ldap/servers/slapd/back-ldbm/ldbm_add.c | 7 ++++++-
ldap/servers/slapd/back-ldbm/parents.c | 6 ++++--
2 files changed, 10 insertions(+), 3 deletions(-)
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
Show replies by date
This is an automated email from the git hooks/post-receive script.
lkrispen pushed a commit to branch master
in repository 389-ds-base.
commit ec4a669cd38bebe90abd3e0c9fb1d6ecd35ef153
Author: Ludwig Krispenz <lkrispen(a)redhat.com>
Date: Thu Feb 22 15:26:35 2018 +0100
ticket 49551 - correctly handle subordinates and tombstone numsubordinates
Additional fix for a case where an ADD is directly turned into a tombstone and teh
tombstone
is resurrected as conflict
Reviewed by: Mark, thanks
---
ldap/servers/slapd/back-ldbm/ldbm_add.c | 7 ++++++-
ldap/servers/slapd/back-ldbm/parents.c | 6 ++++--
2 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/ldap/servers/slapd/back-ldbm/ldbm_add.c
b/ldap/servers/slapd/back-ldbm/ldbm_add.c
index f0a3262..412e1d3 100644
--- a/ldap/servers/slapd/back-ldbm/ldbm_add.c
+++ b/ldap/servers/slapd/back-ldbm/ldbm_add.c
@@ -849,7 +849,12 @@ ldbm_back_add(Slapi_PBlock *pb)
subordinate count specifically */
if (parententry) {
int op = is_resurect_operation ? PARENTUPDATE_RESURECT :
PARENTUPDATE_ADD;
- if (is_cenotaph_operation ) op |= PARENTUPDATE_CREATE_TOMBSTONE;
+ if (is_cenotaph_operation || (is_tombstone_operation && !is_ruv))
{
+ /* if we directly add a tombstone the tombstone numsubordinates have
to be increased
+ * (does not apply to adding the RUV)
+ */
+ op |= PARENTUPDATE_CREATE_TOMBSTONE;
+ }
retval = parent_update_on_childchange(&parent_modify_c, op, NULL);
slapi_log_err(SLAPI_LOG_BACKLDBM, "ldbm_back_add",
"conn=%lu op=%d parent_update_on_childchange:
old_entry=0x%p, new_entry=0x%p, rc=%d\n",
diff --git a/ldap/servers/slapd/back-ldbm/parents.c
b/ldap/servers/slapd/back-ldbm/parents.c
index 1afc795..4583885 100644
--- a/ldap/servers/slapd/back-ldbm/parents.c
+++ b/ldap/servers/slapd/back-ldbm/parents.c
@@ -141,9 +141,11 @@ parent_update_on_childchange(modify_context *mc, int op, size_t
*new_sub_count)
}
/* tombstoneNumSubordinates has to be updated if a tombstone child has been
- * deleted or a tombstone has been directly added (cenotaph) */
+ * deleted or a tombstone has been directly added (cenotaph)
+ * or a tombstone is resurrected
+ */
current_sub_count = LDAP_MAXINT;
- if (repl_op) {
+ if (repl_op || (PARENTUPDATE_RESURECT == op)) {
ret = slapi_entry_attr_find(mc->old_entry->ep_entry,
tombstone_numsubordinates, &read_attr);
if (0 == ret) {
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.