[SCM] Samba Shared Repository - branch master updated - tevent-0-9-8-155-g7c00227

Jeremy Allison jra at samba.org
Thu Sep 10 10:53:50 MDT 2009


The branch, master has been updated
       via  7c00227f00a83345035c4c0a6716b46864f2da8d (commit)
      from  5fb653029529d8cc30dbeb498f7f6d152d17ce17 (commit)

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 7c00227f00a83345035c4c0a6716b46864f2da8d
Author: Marc Aurele La France <tsi at ualberta.ca>
Date:   Thu Sep 10 09:52:11 2009 -0700

    Fix bug 6707 - 3.4.1 segfault in parsing configs.
    Fixes an occasional segfault caused by an out-of-bounds reference in config file parsing.

-----------------------------------------------------------------------

Summary of changes:
 source3/lib/interfaces.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/lib/interfaces.c b/source3/lib/interfaces.c
index bc6c991..b4b3800 100644
--- a/source3/lib/interfaces.c
+++ b/source3/lib/interfaces.c
@@ -156,10 +156,6 @@ static int _get_interfaces(TALLOC_CTX *mem_ctx, struct iface_struct **pifaces)
 	/* Loop through interfaces, looking for given IP address */
 	for (ifptr = iflist; ifptr != NULL; ifptr = ifptr->ifa_next) {
 
-		memset(&ifaces[total], '\0', sizeof(ifaces[total]));
-
-		copy_size = sizeof(struct sockaddr_in);
-
 		if (!ifptr->ifa_addr || !ifptr->ifa_netmask) {
 			continue;
 		}
@@ -169,6 +165,10 @@ static int _get_interfaces(TALLOC_CTX *mem_ctx, struct iface_struct **pifaces)
 			continue;
 		}
 
+		memset(&ifaces[total], '\0', sizeof(ifaces[total]));
+
+		copy_size = sizeof(struct sockaddr_in);
+
 		ifaces[total].flags = ifptr->ifa_flags;
 
 #if defined(HAVE_IPV6)


-- 
Samba Shared Repository


More information about the samba-cvs mailing list