|
|
433de7 |
From b1cc97c13bbbcaa6a3c217d285283203809fa90b Mon Sep 17 00:00:00 2001
|
|
|
433de7 |
From: Thierry Bordaz <tbordaz@redhat.com>
|
|
|
433de7 |
Date: Tue, 16 Oct 2018 10:49:29 +0200
|
|
|
433de7 |
Subject: [PATCH] Ticket 49915 - fix compiler warnings
|
|
|
433de7 |
|
|
|
433de7 |
---
|
|
|
433de7 |
ldap/servers/slapd/back-ldbm/idl_new.c | 2 +-
|
|
|
433de7 |
ldap/servers/slapd/back-ldbm/index.c | 6 +++---
|
|
|
433de7 |
2 files changed, 4 insertions(+), 4 deletions(-)
|
|
|
433de7 |
|
|
|
433de7 |
diff --git a/ldap/servers/slapd/back-ldbm/idl_new.c b/ldap/servers/slapd/back-ldbm/idl_new.c
|
|
|
433de7 |
index 102265c47..81172f590 100644
|
|
|
433de7 |
--- a/ldap/servers/slapd/back-ldbm/idl_new.c
|
|
|
433de7 |
+++ b/ldap/servers/slapd/back-ldbm/idl_new.c
|
|
|
433de7 |
@@ -379,7 +379,7 @@ idl_new_range_fetch(
|
|
|
433de7 |
bck_info.index = SLAPI_ATTR_PARENTID;
|
|
|
433de7 |
bck_info.key = "0";
|
|
|
433de7 |
|
|
|
433de7 |
- if (rc = slapi_back_get_info(be, BACK_INFO_INDEX_KEY, (void **)&bck_info)) {
|
|
|
433de7 |
+ if ((rc = slapi_back_get_info(be, BACK_INFO_INDEX_KEY, (void **)&bck_info))) {
|
|
|
433de7 |
slapi_log_err(SLAPI_LOG_WARNING, "idl_new_range_fetch", "Total update: fail to retrieve suffix entryID, continue assuming it is the first entry\n");
|
|
|
433de7 |
}
|
|
|
433de7 |
if (bck_info.key_found) {
|
|
|
433de7 |
diff --git a/ldap/servers/slapd/back-ldbm/index.c b/ldap/servers/slapd/back-ldbm/index.c
|
|
|
433de7 |
index dea6e9a3e..f0b969ff4 100644
|
|
|
433de7 |
--- a/ldap/servers/slapd/back-ldbm/index.c
|
|
|
433de7 |
+++ b/ldap/servers/slapd/back-ldbm/index.c
|
|
|
433de7 |
@@ -1262,7 +1262,7 @@ set_suffix_key(Slapi_Backend *be, struct _back_info_index_key *info)
|
|
|
433de7 |
/* Start a txn */
|
|
|
433de7 |
li = (struct ldbminfo *)be->be_database->plg_private;
|
|
|
433de7 |
dblayer_txn_init(li, &txn);
|
|
|
433de7 |
- if (rc = dblayer_txn_begin(be, txn.back_txn_txn, &txn)) {
|
|
|
433de7 |
+ if ((rc = dblayer_txn_begin(be, txn.back_txn_txn, &txn))) {
|
|
|
433de7 |
slapi_log_err(SLAPI_LOG_ERR, "set_suffix_key", "Fail to update %s index with %s/%d (key/ID): txn begin fails\n",
|
|
|
433de7 |
info->index, info->key, info->id);
|
|
|
433de7 |
return rc;
|
|
|
433de7 |
@@ -1272,7 +1272,7 @@ set_suffix_key(Slapi_Backend *be, struct _back_info_index_key *info)
|
|
|
433de7 |
sv_key[1] = NULL;
|
|
|
433de7 |
slapi_value_init_string(sv_key[0], info->key);
|
|
|
433de7 |
|
|
|
433de7 |
- if (rc = index_addordel_values_sv(be, info->index, sv_key, NULL, info->id, BE_INDEX_ADD, &txn)) {
|
|
|
433de7 |
+ if ((rc = index_addordel_values_sv(be, info->index, sv_key, NULL, info->id, BE_INDEX_ADD, &txn))) {
|
|
|
433de7 |
value_done(sv_key[0]);
|
|
|
433de7 |
dblayer_txn_abort(be, &txn);
|
|
|
433de7 |
slapi_log_err(SLAPI_LOG_ERR, "set_suffix_key", "Fail to update %s index with %s/%d (key/ID): index_addordel_values_sv fails\n",
|
|
|
433de7 |
@@ -1281,7 +1281,7 @@ set_suffix_key(Slapi_Backend *be, struct _back_info_index_key *info)
|
|
|
433de7 |
}
|
|
|
433de7 |
|
|
|
433de7 |
value_done(sv_key[0]);
|
|
|
433de7 |
- if (rc = dblayer_txn_commit(be, &txn)) {
|
|
|
433de7 |
+ if ((rc = dblayer_txn_commit(be, &txn))) {
|
|
|
433de7 |
slapi_log_err(SLAPI_LOG_ERR, "set_suffix_key", "Fail to update %s index with %s/%d (key/ID): commit fails\n",
|
|
|
433de7 |
info->index, info->key, info->id);
|
|
|
433de7 |
return rc;
|
|
|
433de7 |
--
|
|
|
433de7 |
2.17.2
|
|
|
433de7 |
|