[389-commits] ldap/servers

Richard Allen Megginson rmeggins at fedoraproject.org
Fri Mar 5 15:08:49 UTC 2010


 ldap/servers/slapd/daemon.c |    1 +
 1 file changed, 1 insertion(+)

New commits:
commit d66eb3dd9fdb9648b5058161bf8a7740a16fb2d8
Author: Rich Megginson <rmeggins at redhat.com>
Date:   Thu Mar 4 14:50:38 2010 -0700

    Bug 551198 - LDAPI: incorrect logging to access log - part 2
    
    https://bugzilla.redhat.com/show_bug.cgi?id=551198
    Resolves: bug 551198
    Bug Description: LDAPI: incorrect logging to access log - part 2
    Reviewed by: andrey.ivanov at polytechnique.fr (Thanks!)
    Branch: HEAD
    Fix Description: Initialize the from PRNetAddr to nulls.  That way, if
    PR_Accept doesn't fill in the local fields, we can see that they are
    empty and set the printed from field to "local".
    Platforms tested: RHEL5 x86_64
    Flag Day: no
    Doc impact: no

diff --git a/ldap/servers/slapd/daemon.c b/ldap/servers/slapd/daemon.c
index 3b8986c..0db7f13 100644
--- a/ldap/servers/slapd/daemon.c
+++ b/ldap/servers/slapd/daemon.c
@@ -2075,6 +2075,7 @@ handle_new_connection(Connection_Table *ct, int tcps, PRFileDesc *pr_acceptfd, i
 	PRNetAddr from;
 	PRFileDesc *pr_clonefd = NULL;
 
+	memset(&from, 0, sizeof(from)); /* reset to nulls so we can see what was set */
 	if ( (ns = accept_and_configure( tcps, pr_acceptfd, &from,
 		sizeof(from), secure, local, &pr_clonefd)) == SLAPD_INVALID_SOCKET ) {
 		return -1;




More information about the 389-commits mailing list