~ubuntu-branches/ubuntu/oneiric/squid3/oneiric-security

« back to all changes in this revision

Viewing changes to src/multicast.cc

  • Committer: Bazaar Package Importer
  • Author(s): Luigi Gangitano
  • Date: 2007-05-13 16:03:16 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20070513160316-2h6kn6h1z0q1fvyo
Tags: 3.0.PRE6-1
* New upstream release
  - Removed patches integrated upsteam:
    + 04-m68k-ftbfs

* debian/rules
  - Enable delay pools (Closes: #410785)
  - Enable cache digests (Closes: #416631)
  - Enable ICAP client
  - Raised Max Filedescriptor limit to 65536

* debian/control
  - Added real package dependency for httpd in squid3-cgi

* debian/patches/02-makefile-defaults
  - Fix default configuration file for cachemgr.cgi (Closes: #416630)

* debian/squid3.postinst
  - Fixed bashish in postinst (Closes: #411797)

* debian/patches/05-helpers-typo
  - Added upstream patch fixing compilation error in src/helpers.cc

* debian/patches/06-mem-obj-reference
  - Added upstream patch fixing a mem_obj reference in src/store.cc

* debian/patches/07-close-icap-connections
  - Added upstream patch fixing icap connection starvation

* debian/squid3.rc
  - Added LSB-compliant description to rc script

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
 
2
2
/*
3
 
 * $Id: multicast.cc,v 1.11 2003/02/21 22:50:10 robertc Exp $
 
3
 * $Id: multicast.cc,v 1.12 2007/04/28 22:26:37 hno Exp $
4
4
 *
5
5
 * DEBUG: section 7     Multicast
6
6
 * AUTHOR: Martin Hamilton
42
42
    char ttl = (char) mcast_ttl;
43
43
 
44
44
    if (setsockopt(fd, IPPROTO_IP, IP_MULTICAST_TTL, &ttl, 1) < 0)
45
 
        debug(50, 1) ("comm_set_mcast_ttl: FD %d, TTL: %d: %s\n",
46
 
                      fd, mcast_ttl, xstrerror());
 
45
        debugs(50, 1, "comm_set_mcast_ttl: FD " << fd << ", TTL: " << mcast_ttl << ": " << xstrerror());
47
46
 
48
47
#endif
49
48
 
62
61
    char c = 0;
63
62
 
64
63
    if (ia == NULL) {
65
 
        debug(7, 0) ("comm_join_mcast_groups: Unknown host\n");
 
64
        debugs(7, 0, "comm_join_mcast_groups: Unknown host");
66
65
        return;
67
66
    }
68
67
 
69
68
    for (i = 0; i < (int) ia->count; i++) {
70
 
        debug(7, 10) ("Listening for ICP requests on %s\n",
71
 
                      inet_ntoa(*(ia->in_addrs + i)));
 
69
        debugs(7, 10, "Listening for ICP requests on " << inet_ntoa(*(ia->in_addrs + i)));
72
70
        mr.imr_multiaddr.s_addr = (ia->in_addrs + i)->s_addr;
73
71
        mr.imr_interface.s_addr = INADDR_ANY;
74
72
        x = setsockopt(fd, IPPROTO_IP, IP_ADD_MEMBERSHIP,
76
74
                       (char *) &mr, sizeof(struct ip_mreq));
77
75
 
78
76
        if (x < 0)
79
 
            debug(7, 1) ("comm_join_mcast_groups: FD %d, [%s]\n",
80
 
                         fd, inet_ntoa(*(ia->in_addrs + i)));
 
77
            debugs(7, 1, "comm_join_mcast_groups: FD " << fd << ", [" << inet_ntoa(*(ia->in_addrs + i)) << "]");
81
78
 
82
79
        x = setsockopt(fd, IPPROTO_IP, IP_MULTICAST_LOOP, &c, 1);
83
80
 
84
81
        if (x < 0)
85
 
            debug(7, 1) ("Can't disable multicast loopback: %s\n", xstrerror());
 
82
            debugs(7, 1, "Can't disable multicast loopback: " << xstrerror());
86
83
    }
87
84
 
88
85
#endif