Browse Source

Bug 616500 - fix coverify Defect Type: Resource leaks issues CID 12094 - 12136

https://bugzilla.redhat.com/show_bug.cgi?id=616500
Resolves: bug 616500
Bug description: fix coverify Defect Type: Resource leaks issues CID 12106
description: Fixed resource leaks in internal_plugin_search_referral_callback().
Endi S. Dewata 15 years ago
parent
commit
e5352dbe17
1 changed files with 1 additions and 6 deletions
  1. 1 6
      ldap/servers/slapd/plugin_internal_op.c

+ 1 - 6
ldap/servers/slapd/plugin_internal_op.c

@@ -567,12 +567,7 @@ internal_plugin_search_referral_callback(char *referral, void *callback_data)
   
     /* add this to the list of referrals we are making */   
     this_referral = (Referral_Node *)slapi_ch_calloc(1,sizeof(Referral_Node));
-    
-	if ((this_referral->data = slapi_ch_strdup(referral)) == NULL) 
-    {
-        return(0);
-    }
-
+    this_referral->data = slapi_ch_strdup(referral);
     this_referral->next = ((plugin_search_internal_data *) callback_data)->referral_list_head;
 
     ((plugin_search_internal_data *) callback_data)->referral_list_head = this_referral;