Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7322


Ignore:
Timestamp:
Sep 2, 2010, 3:11:40 AM (14 years ago)
Author:
adrfried
Message:

IPv6 Multicast LANDiscovery

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/ipv6/src/libraries/network/LANDiscovery.cc

    r7295 r7322  
    5353  {
    5454    this->servers_.clear();
     55    ENetPeer* peer;
    5556    ENetAddress address;
    56     enet_address_set_host(&address, "255.255.255.255");
     57    memset(&address, 0, sizeof(ENetAddress));
    5758    address.port = LAN_DISCOVERY_PORT;
    5859
    59     ENetPeer* peer;
     60    /* TODO: check for availability of each protocol */
     61    /* IPv4 */
     62    address.host = ENET_HOST_BROADCAST;
     63    peer = enet_host_connect(this->host_, &address, 0, 0);
     64
     65    /* IPv6 */
     66    enet_address_set_host(&address, "ff02::1"); // TODO: use a multicast group
    6067    peer = enet_host_connect(this->host_, &address, 0, 0);
    6168
Note: See TracChangeset for help on using the changeset viewer.