Blame SOURCES/0069-Ticket-47620-Fix-logically-dead-code.patch

cc3dff
From 1eece8d6d6dc88eb214927992840e5edf270786b Mon Sep 17 00:00:00 2001
cc3dff
From: Mark Reynolds <mreynolds@redhat.com>
cc3dff
Date: Mon, 16 Dec 2013 09:48:12 -0500
cc3dff
Subject: [PATCH 69/78] Ticket 47620 - Fix logically dead code.
cc3dff
cc3dff
Coverity issues:  12419 & 12420
cc3dff
cc3dff
https://fedorahosted.org/389/ticket/47620
cc3dff
cc3dff
Reviewed by: rmeggins(Thanks!)
cc3dff
(cherry picked from commit 080cb44f5eaa794375a8e69b6e1ac09fcae9a961)
cc3dff
(cherry picked from commit c094a9f1a758dabd1164bf979a4ac22bb3720d63)
cc3dff
---
cc3dff
 ldap/servers/plugins/replication/repl5_agmtlist.c       | 12 +-----------
cc3dff
 ldap/servers/plugins/replication/repl5_replica_config.c |  2 +-
cc3dff
 2 files changed, 2 insertions(+), 12 deletions(-)
cc3dff
cc3dff
diff --git a/ldap/servers/plugins/replication/repl5_agmtlist.c b/ldap/servers/plugins/replication/repl5_agmtlist.c
cc3dff
index bd14202..5219c92 100644
cc3dff
--- a/ldap/servers/plugins/replication/repl5_agmtlist.c
cc3dff
+++ b/ldap/servers/plugins/replication/repl5_agmtlist.c
cc3dff
@@ -277,17 +277,7 @@ agmtlist_modify_callback(Slapi_PBlock *pb, Slapi_Entry *entryBefore, Slapi_Entry
cc3dff
                     break;   
cc3dff
                 }
cc3dff
 
cc3dff
-			    /* Start replica initialization */
cc3dff
-                if (val == NULL)
cc3dff
-                {
cc3dff
-                    PR_snprintf (errortext, SLAPI_DSE_RETURNTEXT_SIZE, "No value supplied for attr (%s)", mods[i]->mod_type);
cc3dff
-                    slapi_log_error(SLAPI_LOG_REPL, repl_plugin_name, "agmtlist_modify_callback: %s\n",
cc3dff
-                                    errortext);	  
cc3dff
-                    *returncode = LDAP_UNWILLING_TO_PERFORM;
cc3dff
-                    rc = SLAPI_DSE_CALLBACK_ERROR;
cc3dff
-                    break;
cc3dff
-                }
cc3dff
-            
cc3dff
+                /* Start replica initialization */
cc3dff
                 if (strcasecmp (val, "start") == 0)
cc3dff
                 {                        
cc3dff
                     start_initialize = 1;
cc3dff
diff --git a/ldap/servers/plugins/replication/repl5_replica_config.c b/ldap/servers/plugins/replication/repl5_replica_config.c
cc3dff
index 74e1fb7..853bcde 100644
cc3dff
--- a/ldap/servers/plugins/replication/repl5_replica_config.c
cc3dff
+++ b/ldap/servers/plugins/replication/repl5_replica_config.c
cc3dff
@@ -495,7 +495,7 @@ replica_config_modify (Slapi_PBlock *pb, Slapi_Entry* entryBefore, Slapi_Entry*
cc3dff
                     *returncode = LDAP_SUCCESS;
cc3dff
                 }
cc3dff
                 else if (strcasecmp (config_attr, type_replicaProtocolTimeout) == 0 ){
cc3dff
-                    if (apply_mods && config_attr_value && config_attr_value[0])
cc3dff
+                    if (apply_mods)
cc3dff
                     {
cc3dff
                         long ptimeout = 0;
cc3dff
 
cc3dff
-- 
cc3dff
1.8.1.4
cc3dff