Skip to content

Commit

Permalink
Set a default ipv6 address for multicast (#1959)
Browse files Browse the repository at this point in the history
* Set a good default ipv6 address

Signed-off-by: Ryan Friedman <ryan_friedman@trimble.com>

* Linters

Signed-off-by: Miguel Company <MiguelCompany@eprosima.com>

Co-authored-by: Miguel Company <miguelcompany@eprosima.com>
(cherry picked from commit 6afc1e4)

# Conflicts:
#	src/cpp/rtps/transport/UDPv6Transport.cpp
  • Loading branch information
RFRIEDM-Trimble authored and mergify-bot committed May 14, 2021
1 parent c92a756 commit a05f7a9
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/cpp/rtps/transport/UDPv6Transport.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,8 @@ static asio::ip::address_v6::bytes_type locator_to_native(
IPLocator::getIPv6(locator)[12],
IPLocator::getIPv6(locator)[13],
IPLocator::getIPv6(locator)[14],
IPLocator::getIPv6(locator)[15] } };
IPLocator::getIPv6(locator)[15] }
};
}

UDPv6Transport::UDPv6Transport(
Expand Down Expand Up @@ -141,7 +142,7 @@ bool UDPv6Transport::getDefaultMetatrafficMulticastLocators(
Locator_t locator;
locator.kind = LOCATOR_KIND_UDPv6;
locator.port = static_cast<uint16_t>(metatraffic_multicast_port);
IPLocator::setIPv6(locator, "ff31::8000:1234");
IPLocator::setIPv6(locator, "ff1e::ffff:efff:1");
locators.push_back(locator);
return true;
}
Expand Down Expand Up @@ -202,8 +203,13 @@ void UDPv6Transport::AddDefaultOutputLocator(
LocatorList_t& defaultList)
{
// TODO What is the default IPv6 address?
<<<<<<< HEAD
Locator_t temp;
IPLocator::createLocator(LOCATOR_KIND_UDPv6, "239.255.0.1", 0, temp);
=======
Locator temp;
IPLocator::createLocator(LOCATOR_KIND_UDPv6, "ff1e::ffff:efff:1", 0, temp);
>>>>>>> 6afc1e422... Set a default ipv6 address for multicast (#1959)
defaultList.push_back(temp);
}

Expand Down

0 comments on commit a05f7a9

Please sign in to comment.