[SCM] Samba Shared Repository - branch v3-2-test updated - initial-v3-2-test-2488-g2534160

Michael Adam obnox at samba.org
Fri Feb 22 09:48:04 GMT 2008


The branch, v3-2-test has been updated
       via  25341602ec8752e19ab993872dc2f6c4762785ff (commit)
      from  7970901223464745f99cea883b180316189e4b2c (commit)

http://gitweb.samba.org/?samba.git;a=shortlog;h=v3-2-test


- Log -----------------------------------------------------------------
commit 25341602ec8752e19ab993872dc2f6c4762785ff
Author: Michael Adam <obnox at samba.org>
Date:   Fri Feb 22 10:43:42 2008 +0100

    Not all implementations of struct ifaddrs define ifa_broadaddr.
    
    E.g. the definition of libreplace doesn't. :-o
    
    Michael

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

Summary of changes:
 source/lib/interfaces.c |   16 +++-------------
 1 files changed, 3 insertions(+), 13 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source/lib/interfaces.c b/source/lib/interfaces.c
index 8925958..dd857ae 100644
--- a/source/lib/interfaces.c
+++ b/source/lib/interfaces.c
@@ -236,19 +236,9 @@ static int _get_interfaces(struct iface_struct *ifaces, int max_interfaces)
 		memcpy(&ifaces[total].netmask, ifptr->ifa_netmask, copy_size);
 
 		if (ifaces[total].flags & (IFF_BROADCAST|IFF_LOOPBACK)) {
-			if (ifptr->ifa_broadaddr) {
-				memcpy(&ifaces[total].bcast,
-					ifptr->ifa_broadaddr,
-					copy_size);
-			} else {
-				/* For some reason ifptr->ifa_broadaddr
-				 * is null. Make one from ifa_addr and
-				 * ifa_netmask.
-				 */
-				make_bcast(&ifaces[total].bcast,
-					&ifaces[total].ip,
-					&ifaces[total].netmask);
-			}
+			make_bcast(&ifaces[total].bcast,
+				&ifaces[total].ip,
+				&ifaces[total].netmask);
 		} else if ((ifaces[total].flags & IFF_POINTOPOINT) &&
 			       ifptr->ifa_dstaddr ) {
 			memcpy(&ifaces[total].bcast,


-- 
Samba Shared Repository


More information about the samba-cvs mailing list