[Fedora-directory-commits] ldapserver/ldap/servers/slapd filterentry.c, 1.4, 1.4.2.1

Noriko Hosoi (nhosoi) fedora-directory-commits at redhat.com
Wed Jan 16 01:50:20 UTC 2008


Author: nhosoi

Update of /cvs/dirsec/ldapserver/ldap/servers/slapd
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv12525

Modified Files:
      Tag: Directory71RtmBranch
	filterentry.c 
Log Message:
Resolves: #428764
Summary: memory leaks in extensible filter code
Description: applied the patch to Directory71RtmBranch



Index: filterentry.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/filterentry.c,v
retrieving revision 1.4
retrieving revision 1.4.2.1
diff -u -r1.4 -r1.4.2.1
--- filterentry.c	19 Apr 2005 22:07:36 -0000	1.4
+++ filterentry.c	16 Jan 2008 01:50:17 -0000	1.4.2.1
@@ -436,6 +436,7 @@
                         bv.bv_len = strlen(val);
                         bvec[0] = &bv;
                         attrlist_merge (&dnAttrs, type, bvec);
+                        slapi_ch_free_string( &type );
                     }
                 }
                 ldap_value_free (avas);
@@ -500,7 +501,7 @@
 					/* B) Also check the DN attributes for the attribute value */
 					Slapi_Attr* dnattrs= dn2attrs(slapi_entry_get_dn_const(e));
 					rc= test_ava_filter( callers_pb, e, dnattrs, &a, LDAP_FILTER_EQUALITY, 0 /* Don't Verify Access */ , 0 /* don't just verify access */, access_check_done );
-        			slapi_attr_free( &dnattrs );
+        			attrlist_free( dnattrs );
 				}
 			}
 			else
@@ -515,7 +516,7 @@
 					/* D & F) Also check the DN attributes for the attribute value */
 					Slapi_Attr* dnattrs= dn2attrs(slapi_entry_get_dn_const(e));
 					mrf->mrf_match (mrf->mrf_object, e, dnattrs);
-        			slapi_attr_free( &dnattrs );
+        			attrlist_free( dnattrs );
 				}
 			}
 		}
@@ -568,7 +569,7 @@
 					/* B) Also check the DN attributes for the attribute value */
 					Slapi_Attr* dnattrs= dn2attrs(slapi_entry_get_dn_const(e));
 					rc= test_ava_filter( callers_pb, e, dnattrs, &a, LDAP_FILTER_EQUALITY, 0 /* Don't Verify Access */ , 0 /* don't just verify access */, access_check_done );
-        			slapi_attr_free( &dnattrs );
+        			attrlist_free( dnattrs );
 				}
 			}
 			else
@@ -583,7 +584,7 @@
 					/* D & F) Also check the DN attributes for the attribute value */
 					Slapi_Attr* dnattrs= dn2attrs(slapi_entry_get_dn_const(e));
 					mrf->mrf_match (mrf->mrf_object, e, dnattrs);
-        			slapi_attr_free( &dnattrs );
+        			attrlist_free( dnattrs );
 				}
 			}
 		}




More information about the Fedora-directory-commits mailing list