From 59fa11dff675f471c0c6c2997e724f1389b87ac5 Mon Sep 17 00:00:00 2001 From: bms Date: Mon, 9 Apr 2007 19:44:08 +0000 Subject: [PATCH] Fix a bug whereby group addresses were incorrectly computed in the test. [Since the change to strict refcounting for in_multi objects, this test began to fail; formerly the refcount was a count of the number of requests for a given address, NOT a count of pointers to the object.] --- tools/regression/netinet/ipsockopt/ipsockopt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/regression/netinet/ipsockopt/ipsockopt.c b/tools/regression/netinet/ipsockopt/ipsockopt.c index 9abaf7a8e74c..ffcb48efab2a 100644 --- a/tools/regression/netinet/ipsockopt/ipsockopt.c +++ b/tools/regression/netinet/ipsockopt/ipsockopt.c @@ -680,7 +680,7 @@ test_ip_multicast_membership(int sock, const char *socktypename) * route is pointing. */ for (i = 0; i < nmcastgroups; i++) { - mreq.imr_multiaddr.s_addr = htonl((basegroup | i)); + mreq.imr_multiaddr.s_addr = htonl((basegroup + i)); mreq.imr_interface.s_addr = INADDR_ANY; inet_ntop(AF_INET, &mreq.imr_multiaddr, addrbuf, sizeof(addrbuf)); if (verbose) @@ -693,7 +693,7 @@ test_ip_multicast_membership(int sock, const char *socktypename) } } for (i = 0; i < nmcastgroups; i++) { - mreq.imr_multiaddr.s_addr = htonl((basegroup | i)); + mreq.imr_multiaddr.s_addr = htonl((basegroup + i)); mreq.imr_interface.s_addr = INADDR_ANY; inet_ntop(AF_INET, &mreq.imr_multiaddr, addrbuf, sizeof(addrbuf)); if (verbose)