Browse Source

coverity 12606 Logically dead code

The previous fix (commit 325abca7135d06225adf5380d726de60dacda5a4)
for "Ticket #303 - make DNA range requests work with transactions"
introduced this dead code.  Since dna_pre_op does not allocate
an entry "e", there is no need to check the flag "free_entry" and
free it.

Reviewed by [email protected] (Thanks, Mark!!).
Noriko Hosoi 13 years ago
parent
commit
77cacd96c1
1 changed files with 0 additions and 4 deletions
  1. 0 4
      ldap/servers/plugins/dna/dna.c

+ 0 - 4
ldap/servers/plugins/dna/dna.c

@@ -3214,7 +3214,6 @@ dna_pre_op(Slapi_PBlock * pb, int modtype)
     char *dn = NULL;
     Slapi_Mods *smods = NULL;
     LDAPMod **mods;
-    int free_entry = 0;
     int ret = 0;
 
     slapi_log_error(SLAPI_LOG_TRACE, DNA_PLUGIN_SUBSYSTEM,
@@ -3308,9 +3307,6 @@ dna_pre_op(Slapi_PBlock * pb, int modtype)
         slapi_mods_free(&smods);
     }
 bail:
-    if (free_entry && e)
-        slapi_entry_free(e);
-
     if (resulting_e)
         slapi_entry_free(resulting_e);