Blame SOURCES/0007-Issue-51110-Fix-ASAN-ODR-warnings.patch

a26cad
From a1cd3cf8e8b6b33ab21d5338921187a76dd9dcd0 Mon Sep 17 00:00:00 2001
a26cad
From: Mark Reynolds <mreynolds@redhat.com>
a26cad
Date: Fri, 22 May 2020 15:41:45 -0400
a26cad
Subject: [PATCH 07/12] Issue 51110 - Fix ASAN ODR warnings
a26cad
a26cad
Description: Fixed ODR issues with glboal attributes which were duplicated from
a26cad
             the core server into the replication and retrocl plugins.
a26cad
a26cad
relates: https://pagure.io/389-ds-base/issue/51110
a26cad
a26cad
Reviewed by: firstyear(Thanks!)
a26cad
---
a26cad
 ldap/servers/plugins/replication/repl5.h      | 17 +++---
a26cad
 .../plugins/replication/repl_globals.c        | 17 +++---
a26cad
 ldap/servers/plugins/replication/replutil.c   | 16 +++---
a26cad
 ldap/servers/plugins/retrocl/retrocl.h        | 22 ++++----
a26cad
 ldap/servers/plugins/retrocl/retrocl_cn.c     | 12 ++---
a26cad
 ldap/servers/plugins/retrocl/retrocl_po.c     | 52 +++++++++----------
a26cad
 ldap/servers/plugins/retrocl/retrocl_trim.c   | 30 +++++------
a26cad
 7 files changed, 82 insertions(+), 84 deletions(-)
a26cad
a26cad
diff --git a/ldap/servers/plugins/replication/repl5.h b/ldap/servers/plugins/replication/repl5.h
a26cad
index 873dd8a16..72b7089e3 100644
a26cad
--- a/ldap/servers/plugins/replication/repl5.h
a26cad
+++ b/ldap/servers/plugins/replication/repl5.h
a26cad
@@ -280,15 +280,14 @@ struct berval *NSDS90StartReplicationRequest_new(const char *protocol_oid,
a26cad
 int multimaster_extop_NSDS50ReplicationEntry(Slapi_PBlock *pb);
a26cad
 
a26cad
 /* From repl_globals.c */
a26cad
-extern char *attr_changenumber;
a26cad
-extern char *attr_targetdn;
a26cad
-extern char *attr_changetype;
a26cad
-extern char *attr_newrdn;
a26cad
-extern char *attr_deleteoldrdn;
a26cad
-extern char *attr_changes;
a26cad
-extern char *attr_newsuperior;
a26cad
-extern char *attr_changetime;
a26cad
-extern char *attr_dataversion;
a26cad
+extern char *repl_changenumber;
a26cad
+extern char *repl_targetdn;
a26cad
+extern char *repl_changetype;
a26cad
+extern char *repl_newrdn;
a26cad
+extern char *repl_deleteoldrdn;
a26cad
+extern char *repl_changes;
a26cad
+extern char *repl_newsuperior;
a26cad
+extern char *repl_changetime;
a26cad
 extern char *attr_csn;
a26cad
 extern char *changetype_add;
a26cad
 extern char *changetype_delete;
a26cad
diff --git a/ldap/servers/plugins/replication/repl_globals.c b/ldap/servers/plugins/replication/repl_globals.c
a26cad
index 355a0ffa1..c615c77da 100644
a26cad
--- a/ldap/servers/plugins/replication/repl_globals.c
a26cad
+++ b/ldap/servers/plugins/replication/repl_globals.c
a26cad
@@ -48,15 +48,14 @@ char *changetype_delete = CHANGETYPE_DELETE;
a26cad
 char *changetype_modify = CHANGETYPE_MODIFY;
a26cad
 char *changetype_modrdn = CHANGETYPE_MODRDN;
a26cad
 char *changetype_moddn = CHANGETYPE_MODDN;
a26cad
-char *attr_changenumber = ATTR_CHANGENUMBER;
a26cad
-char *attr_targetdn = ATTR_TARGETDN;
a26cad
-char *attr_changetype = ATTR_CHANGETYPE;
a26cad
-char *attr_newrdn = ATTR_NEWRDN;
a26cad
-char *attr_deleteoldrdn = ATTR_DELETEOLDRDN;
a26cad
-char *attr_changes = ATTR_CHANGES;
a26cad
-char *attr_newsuperior = ATTR_NEWSUPERIOR;
a26cad
-char *attr_changetime = ATTR_CHANGETIME;
a26cad
-char *attr_dataversion = ATTR_DATAVERSION;
a26cad
+char *repl_changenumber = ATTR_CHANGENUMBER;
a26cad
+char *repl_targetdn = ATTR_TARGETDN;
a26cad
+char *repl_changetype = ATTR_CHANGETYPE;
a26cad
+char *repl_newrdn = ATTR_NEWRDN;
a26cad
+char *repl_deleteoldrdn = ATTR_DELETEOLDRDN;
a26cad
+char *repl_changes = ATTR_CHANGES;
a26cad
+char *repl_newsuperior = ATTR_NEWSUPERIOR;
a26cad
+char *repl_changetime = ATTR_CHANGETIME;
a26cad
 char *attr_csn = ATTR_CSN;
a26cad
 char *type_copyingFrom = TYPE_COPYINGFROM;
a26cad
 char *type_copiedFrom = TYPE_COPIEDFROM;
a26cad
diff --git a/ldap/servers/plugins/replication/replutil.c b/ldap/servers/plugins/replication/replutil.c
a26cad
index de1e77880..39f821d12 100644
a26cad
--- a/ldap/servers/plugins/replication/replutil.c
a26cad
+++ b/ldap/servers/plugins/replication/replutil.c
a26cad
@@ -64,14 +64,14 @@ get_cleattrs()
a26cad
 {
a26cad
     if (cleattrs[0] == NULL) {
a26cad
         cleattrs[0] = type_objectclass;
a26cad
-        cleattrs[1] = attr_changenumber;
a26cad
-        cleattrs[2] = attr_targetdn;
a26cad
-        cleattrs[3] = attr_changetype;
a26cad
-        cleattrs[4] = attr_newrdn;
a26cad
-        cleattrs[5] = attr_deleteoldrdn;
a26cad
-        cleattrs[6] = attr_changes;
a26cad
-        cleattrs[7] = attr_newsuperior;
a26cad
-        cleattrs[8] = attr_changetime;
a26cad
+        cleattrs[1] = repl_changenumber;
a26cad
+        cleattrs[2] = repl_targetdn;
a26cad
+        cleattrs[3] = repl_changetype;
a26cad
+        cleattrs[4] = repl_newrdn;
a26cad
+        cleattrs[5] = repl_deleteoldrdn;
a26cad
+        cleattrs[6] = repl_changes;
a26cad
+        cleattrs[7] = repl_newsuperior;
a26cad
+        cleattrs[8] = repl_changetime;
a26cad
         cleattrs[9] = NULL;
a26cad
     }
a26cad
     return cleattrs;
a26cad
diff --git a/ldap/servers/plugins/retrocl/retrocl.h b/ldap/servers/plugins/retrocl/retrocl.h
a26cad
index 06482a14c..2ce76fcec 100644
a26cad
--- a/ldap/servers/plugins/retrocl/retrocl.h
a26cad
+++ b/ldap/servers/plugins/retrocl/retrocl.h
a26cad
@@ -94,17 +94,17 @@ extern int retrocl_nattributes;
a26cad
 extern char **retrocl_attributes;
a26cad
 extern char **retrocl_aliases;
a26cad
 
a26cad
-extern const char *attr_changenumber;
a26cad
-extern const char *attr_targetdn;
a26cad
-extern const char *attr_changetype;
a26cad
-extern const char *attr_newrdn;
a26cad
-extern const char *attr_newsuperior;
a26cad
-extern const char *attr_deleteoldrdn;
a26cad
-extern const char *attr_changes;
a26cad
-extern const char *attr_changetime;
a26cad
-extern const char *attr_objectclass;
a26cad
-extern const char *attr_nsuniqueid;
a26cad
-extern const char *attr_isreplicated;
a26cad
+extern const char *retrocl_changenumber;
a26cad
+extern const char *retrocl_targetdn;
a26cad
+extern const char *retrocl_changetype;
a26cad
+extern const char *retrocl_newrdn;
a26cad
+extern const char *retrocl_newsuperior;
a26cad
+extern const char *retrocl_deleteoldrdn;
a26cad
+extern const char *retrocl_changes;
a26cad
+extern const char *retrocl_changetime;
a26cad
+extern const char *retrocl_objectclass;
a26cad
+extern const char *retrocl_nsuniqueid;
a26cad
+extern const char *retrocl_isreplicated;
a26cad
 
a26cad
 extern PRLock *retrocl_internal_lock;
a26cad
 extern Slapi_RWLock *retrocl_cn_lock;
a26cad
diff --git a/ldap/servers/plugins/retrocl/retrocl_cn.c b/ldap/servers/plugins/retrocl/retrocl_cn.c
a26cad
index 709d7a857..5fc5f586d 100644
a26cad
--- a/ldap/servers/plugins/retrocl/retrocl_cn.c
a26cad
+++ b/ldap/servers/plugins/retrocl/retrocl_cn.c
a26cad
@@ -62,7 +62,7 @@ handle_cnum_entry(Slapi_Entry *e, void *callback_data)
a26cad
         Slapi_Attr *chattr = NULL;
a26cad
         sval = NULL;
a26cad
         value = NULL;
a26cad
-        if (slapi_entry_attr_find(e, attr_changenumber, &chattr) == 0) {
a26cad
+        if (slapi_entry_attr_find(e, retrocl_changenumber, &chattr) == 0) {
a26cad
             slapi_attr_first_value(chattr, &sval);
a26cad
             if (NULL != sval) {
a26cad
                 value = slapi_value_get_berval(sval);
a26cad
@@ -79,7 +79,7 @@ handle_cnum_entry(Slapi_Entry *e, void *callback_data)
a26cad
         chattr = NULL;
a26cad
         sval = NULL;
a26cad
         value = NULL;
a26cad
-        if (slapi_entry_attr_find(e, attr_changetime, &chattr) == 0) {
a26cad
+        if (slapi_entry_attr_find(e, retrocl_changetime, &chattr) == 0) {
a26cad
             slapi_attr_first_value(chattr, &sval);
a26cad
             if (NULL != sval) {
a26cad
                 value = slapi_value_get_berval(sval);
a26cad
@@ -134,7 +134,7 @@ retrocl_get_changenumbers(void)
a26cad
     cr.cr_time = 0;
a26cad
 
a26cad
     slapi_seq_callback(RETROCL_CHANGELOG_DN, SLAPI_SEQ_FIRST,
a26cad
-                       (char *)attr_changenumber, /* cast away const */
a26cad
+                       (char *)retrocl_changenumber, /* cast away const */
a26cad
                        NULL, NULL, 0, &cr, NULL, handle_cnum_result,
a26cad
                        handle_cnum_entry, NULL);
a26cad
 
a26cad
@@ -144,7 +144,7 @@ retrocl_get_changenumbers(void)
a26cad
     slapi_ch_free((void **)&cr.cr_time);
a26cad
 
a26cad
     slapi_seq_callback(RETROCL_CHANGELOG_DN, SLAPI_SEQ_LAST,
a26cad
-                       (char *)attr_changenumber, /* cast away const */
a26cad
+                       (char *)retrocl_changenumber, /* cast away const */
a26cad
                        NULL, NULL, 0, &cr, NULL, handle_cnum_result,
a26cad
                        handle_cnum_entry, NULL);
a26cad
 
a26cad
@@ -185,7 +185,7 @@ retrocl_getchangetime(int type, int *err)
a26cad
         return NO_TIME;
a26cad
     }
a26cad
     slapi_seq_callback(RETROCL_CHANGELOG_DN, type,
a26cad
-                       (char *)attr_changenumber, /* cast away const */
a26cad
+                       (char *)retrocl_changenumber, /* cast away const */
a26cad
                        NULL,
a26cad
                        NULL, 0, &cr, NULL,
a26cad
                        handle_cnum_result, handle_cnum_entry, NULL);
a26cad
@@ -353,7 +353,7 @@ retrocl_update_lastchangenumber(void)
a26cad
     cr.cr_cnum = 0;
a26cad
     cr.cr_time = 0;
a26cad
     slapi_seq_callback(RETROCL_CHANGELOG_DN, SLAPI_SEQ_LAST,
a26cad
-                       (char *)attr_changenumber, /* cast away const */
a26cad
+                       (char *)retrocl_changenumber, /* cast away const */
a26cad
                        NULL, NULL, 0, &cr, NULL, handle_cnum_result,
a26cad
                        handle_cnum_entry, NULL);
a26cad
 
a26cad
diff --git a/ldap/servers/plugins/retrocl/retrocl_po.c b/ldap/servers/plugins/retrocl/retrocl_po.c
a26cad
index d2af79b31..e1488f56b 100644
a26cad
--- a/ldap/servers/plugins/retrocl/retrocl_po.c
a26cad
+++ b/ldap/servers/plugins/retrocl/retrocl_po.c
a26cad
@@ -25,17 +25,17 @@ modrdn2reple(Slapi_Entry *e, const char *newrdn, int deloldrdn, LDAPMod **ldm, c
a26cad
 
a26cad
 /******************************/
a26cad
 
a26cad
-const char *attr_changenumber = "changenumber";
a26cad
-const char *attr_targetdn = "targetdn";
a26cad
-const char *attr_changetype = "changetype";
a26cad
-const char *attr_newrdn = "newrdn";
a26cad
-const char *attr_deleteoldrdn = "deleteoldrdn";
a26cad
-const char *attr_changes = "changes";
a26cad
-const char *attr_newsuperior = "newsuperior";
a26cad
-const char *attr_changetime = "changetime";
a26cad
-const char *attr_objectclass = "objectclass";
a26cad
-const char *attr_nsuniqueid = "nsuniqueid";
a26cad
-const char *attr_isreplicated = "isreplicated";
a26cad
+const char *retrocl_changenumber = "changenumber";
a26cad
+const char *retrocl_targetdn = "targetdn";
a26cad
+const char *retrocl_changetype = "changetype";
a26cad
+const char *retrocl_newrdn = "newrdn";
a26cad
+const char *retrocl_deleteoldrdn = "deleteoldrdn";
a26cad
+const char *retrocl_changes = "changes";
a26cad
+const char *retrocl_newsuperior = "newsuperior";
a26cad
+const char *retrocl_changetime = "changetime";
a26cad
+const char *retrocl_objectclass = "objectclass";
a26cad
+const char *retrocl_nsuniqueid = "nsuniqueid";
a26cad
+const char *retrocl_isreplicated = "isreplicated";
a26cad
 
a26cad
 /*
a26cad
  * Function: make_changes_string
a26cad
@@ -185,7 +185,7 @@ write_replog_db(
a26cad
                   changenum, dn);
a26cad
 
a26cad
     /* Construct the dn of this change record */
a26cad
-    edn = slapi_ch_smprintf("%s=%lu,%s", attr_changenumber, changenum, RETROCL_CHANGELOG_DN);
a26cad
+    edn = slapi_ch_smprintf("%s=%lu,%s", retrocl_changenumber, changenum, RETROCL_CHANGELOG_DN);
a26cad
 
a26cad
     /*
a26cad
      * Create the entry struct, and fill in fields common to all types
a26cad
@@ -214,7 +214,7 @@ write_replog_db(
a26cad
             attributeAlias = attributeName;
a26cad
         }
a26cad
 
a26cad
-        if (strcasecmp(attributeName, attr_nsuniqueid) == 0) {
a26cad
+        if (strcasecmp(attributeName, retrocl_nsuniqueid) == 0) {
a26cad
             Slapi_Entry *entry = NULL;
a26cad
             const char *uniqueId = NULL;
a26cad
 
a26cad
@@ -236,7 +236,7 @@ write_replog_db(
a26cad
 
a26cad
             extensibleObject = 1;
a26cad
 
a26cad
-        } else if (strcasecmp(attributeName, attr_isreplicated) == 0) {
a26cad
+        } else if (strcasecmp(attributeName, retrocl_isreplicated) == 0) {
a26cad
             int isReplicated = 0;
a26cad
             char *attributeValue = NULL;
a26cad
 
a26cad
@@ -298,17 +298,17 @@ write_replog_db(
a26cad
     sprintf(chnobuf, "%lu", changenum);
a26cad
     val.bv_val = chnobuf;
a26cad
     val.bv_len = strlen(chnobuf);
a26cad
-    slapi_entry_add_values(e, attr_changenumber, vals);
a26cad
+    slapi_entry_add_values(e, retrocl_changenumber, vals);
a26cad
 
a26cad
     /* Set the targetentrydn attribute */
a26cad
     val.bv_val = dn;
a26cad
     val.bv_len = strlen(dn);
a26cad
-    slapi_entry_add_values(e, attr_targetdn, vals);
a26cad
+    slapi_entry_add_values(e, retrocl_targetdn, vals);
a26cad
 
a26cad
     /* Set the changeTime attribute */
a26cad
     val.bv_val = format_genTime(curtime);
a26cad
     val.bv_len = strlen(val.bv_val);
a26cad
-    slapi_entry_add_values(e, attr_changetime, vals);
a26cad
+    slapi_entry_add_values(e, retrocl_changetime, vals);
a26cad
     slapi_ch_free((void **)&val.bv_val);
a26cad
 
a26cad
     /*
a26cad
@@ -344,7 +344,7 @@ write_replog_db(
a26cad
             /* Set the changetype attribute */
a26cad
             val.bv_val = "delete";
a26cad
             val.bv_len = 6;
a26cad
-            slapi_entry_add_values(e, attr_changetype, vals);
a26cad
+            slapi_entry_add_values(e, retrocl_changetype, vals);
a26cad
         }
a26cad
         break;
a26cad
 
a26cad
@@ -422,7 +422,7 @@ entry2reple(Slapi_Entry *e, Slapi_Entry *oe, int optype)
a26cad
     } else {
a26cad
         return (1);
a26cad
     }
a26cad
-    slapi_entry_add_values(e, attr_changetype, vals);
a26cad
+    slapi_entry_add_values(e, retrocl_changetype, vals);
a26cad
 
a26cad
     estr = slapi_entry2str(oe, &len;;
a26cad
     p = estr;
a26cad
@@ -435,7 +435,7 @@ entry2reple(Slapi_Entry *e, Slapi_Entry *oe, int optype)
a26cad
     }
a26cad
     val.bv_val = p;
a26cad
     val.bv_len = len - (p - estr); /* length + terminating \0 */
a26cad
-    slapi_entry_add_values(e, attr_changes, vals);
a26cad
+    slapi_entry_add_values(e, retrocl_changes, vals);
a26cad
     slapi_ch_free_string(&estr);
a26cad
     return 0;
a26cad
 }
a26cad
@@ -471,7 +471,7 @@ mods2reple(Slapi_Entry *e, LDAPMod **ldm)
a26cad
         if (NULL != l) {
a26cad
             val.bv_val = l->ls_buf;
a26cad
             val.bv_len = l->ls_len + 1; /* string + terminating \0 */
a26cad
-            slapi_entry_add_values(e, attr_changes, vals);
a26cad
+            slapi_entry_add_values(e, retrocl_changes, vals);
a26cad
             lenstr_free(&l);
a26cad
         }
a26cad
     }
a26cad
@@ -511,12 +511,12 @@ modrdn2reple(
a26cad
 
a26cad
     val.bv_val = "modrdn";
a26cad
     val.bv_len = 6;
a26cad
-    slapi_entry_add_values(e, attr_changetype, vals);
a26cad
+    slapi_entry_add_values(e, retrocl_changetype, vals);
a26cad
 
a26cad
     if (newrdn) {
a26cad
         val.bv_val = (char *)newrdn; /* cast away const */
a26cad
         val.bv_len = strlen(newrdn);
a26cad
-        slapi_entry_add_values(e, attr_newrdn, vals);
a26cad
+        slapi_entry_add_values(e, retrocl_newrdn, vals);
a26cad
     }
a26cad
 
a26cad
     if (deloldrdn == 0) {
a26cad
@@ -526,12 +526,12 @@ modrdn2reple(
a26cad
         val.bv_val = "TRUE";
a26cad
         val.bv_len = 4;
a26cad
     }
a26cad
-    slapi_entry_add_values(e, attr_deleteoldrdn, vals);
a26cad
+    slapi_entry_add_values(e, retrocl_deleteoldrdn, vals);
a26cad
 
a26cad
     if (newsuperior) {
a26cad
         val.bv_val = (char *)newsuperior; /* cast away const */
a26cad
         val.bv_len = strlen(newsuperior);
a26cad
-        slapi_entry_add_values(e, attr_newsuperior, vals);
a26cad
+        slapi_entry_add_values(e, retrocl_newsuperior, vals);
a26cad
     }
a26cad
 
a26cad
     if (NULL != ldm) {
a26cad
@@ -540,7 +540,7 @@ modrdn2reple(
a26cad
             if (l->ls_len) {
a26cad
                 val.bv_val = l->ls_buf;
a26cad
                 val.bv_len = l->ls_len;
a26cad
-                slapi_entry_add_values(e, attr_changes, vals);
a26cad
+                slapi_entry_add_values(e, retrocl_changes, vals);
a26cad
             }
a26cad
             lenstr_free(&l);
a26cad
         }
a26cad
diff --git a/ldap/servers/plugins/retrocl/retrocl_trim.c b/ldap/servers/plugins/retrocl/retrocl_trim.c
a26cad
index 0378eb7f6..d031dc3f8 100644
a26cad
--- a/ldap/servers/plugins/retrocl/retrocl_trim.c
a26cad
+++ b/ldap/servers/plugins/retrocl/retrocl_trim.c
a26cad
@@ -49,15 +49,15 @@ static const char **
a26cad
 get_cleattrs(void)
a26cad
 {
a26cad
     if (cleattrs[0] == NULL) {
a26cad
-        cleattrs[0] = attr_objectclass;
a26cad
-        cleattrs[1] = attr_changenumber;
a26cad
-        cleattrs[2] = attr_targetdn;
a26cad
-        cleattrs[3] = attr_changetype;
a26cad
-        cleattrs[4] = attr_newrdn;
a26cad
-        cleattrs[5] = attr_deleteoldrdn;
a26cad
-        cleattrs[6] = attr_changes;
a26cad
-        cleattrs[7] = attr_newsuperior;
a26cad
-        cleattrs[8] = attr_changetime;
a26cad
+        cleattrs[0] = retrocl_objectclass;
a26cad
+        cleattrs[1] = retrocl_changenumber;
a26cad
+        cleattrs[2] = retrocl_targetdn;
a26cad
+        cleattrs[3] = retrocl_changetype;
a26cad
+        cleattrs[4] = retrocl_newrdn;
a26cad
+        cleattrs[5] = retrocl_deleteoldrdn;
a26cad
+        cleattrs[6] = retrocl_changes;
a26cad
+        cleattrs[7] = retrocl_newsuperior;
a26cad
+        cleattrs[8] = retrocl_changetime;
a26cad
         cleattrs[9] = NULL;
a26cad
     }
a26cad
     return cleattrs;
a26cad
@@ -81,7 +81,7 @@ delete_changerecord(changeNumber cnum)
a26cad
     char *dnbuf;
a26cad
     int delrc;
a26cad
 
a26cad
-    dnbuf = slapi_ch_smprintf("%s=%ld, %s", attr_changenumber, cnum,
a26cad
+    dnbuf = slapi_ch_smprintf("%s=%ld, %s", retrocl_changenumber, cnum,
a26cad
                               RETROCL_CHANGELOG_DN);
a26cad
     pb = slapi_pblock_new();
a26cad
     slapi_delete_internal_set_pb(pb, dnbuf, NULL /*controls*/, NULL /* uniqueid */,
a26cad
@@ -154,7 +154,7 @@ handle_getchangetime_search(Slapi_Entry *e, void *callback_data)
a26cad
         if (NULL != e) {
a26cad
             Slapi_Value *sval = NULL;
a26cad
             const struct berval *val = NULL;
a26cad
-            rc = slapi_entry_attr_find(e, attr_changetime, &attr);
a26cad
+            rc = slapi_entry_attr_find(e, retrocl_changetime, &attr);
a26cad
             /* Bug 624442: Logic checking for lack of timestamp was
a26cad
                reversed. */
a26cad
             if (0 != rc || slapi_attr_first_value(attr, &sval) == -1 ||
a26cad
@@ -174,14 +174,14 @@ handle_getchangetime_search(Slapi_Entry *e, void *callback_data)
a26cad
 /*
a26cad
  * Function: get_changetime
a26cad
  * Arguments: cnum - number of change record to retrieve
a26cad
- * Returns: Taking the attr_changetime of the 'cnum' entry,
a26cad
+ * Returns: Taking the retrocl_changetime of the 'cnum' entry,
a26cad
  * it converts it into time_t (parse_localTime) and returns this time value.
a26cad
  * It returns 0 in the following cases:
a26cad
- *  - changerecord entry has not attr_changetime
a26cad
+ *  - changerecord entry has not retrocl_changetime
a26cad
  *  - attr_changetime attribute has no value
a26cad
  *  - attr_changetime attribute value is empty
a26cad
  *
a26cad
- * Description: Retrieve attr_changetime ("changetime") from a changerecord whose number is "cnum".
a26cad
+ * Description: Retrieve retrocl_changetime ("changetime") from a changerecord whose number is "cnum".
a26cad
  */
a26cad
 static time_t
a26cad
 get_changetime(changeNumber cnum, int *err)
a26cad
@@ -198,7 +198,7 @@ get_changetime(changeNumber cnum, int *err)
a26cad
     }
a26cad
     crtp->crt_nentries = crtp->crt_err = 0;
a26cad
     crtp->crt_time = 0;
a26cad
-    PR_snprintf(fstr, sizeof(fstr), "%s=%ld", attr_changenumber, cnum);
a26cad
+    PR_snprintf(fstr, sizeof(fstr), "%s=%ld", retrocl_changenumber, cnum);
a26cad
 
a26cad
     pb = slapi_pblock_new();
a26cad
     slapi_search_internal_set_pb(pb, RETROCL_CHANGELOG_DN,
a26cad
-- 
a26cad
2.26.2
a26cad