Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for API break on Fast RTPS 2.0 #370

Merged
merged 1 commit into from
Apr 21, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions rmw_fastrtps_shared_cpp/src/participant.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,6 @@ rmw_fastrtps_shared_cpp::create_participant(
// Load default XML profile.
Domain::getDefaultParticipantAttributes(participantAttrs);

participantAttrs.rtps.builtin.domainId = static_cast<uint32_t>(domain_id);

if (localhost_only) {
Locator_t local_network_interface_locator;
static const std::string local_ip_name("127.0.0.1");
Expand All @@ -165,7 +163,11 @@ rmw_fastrtps_shared_cpp::create_participant(
participantAttrs.rtps.builtin.initialPeersList.push_back(local_network_interface_locator);
}

#if FASTRTPS_VERSION_MAJOR < 2
participantAttrs.rtps.builtin.domainId = static_cast<uint32_t>(domain_id);
#else
participantAttrs.domainId = static_cast<uint32_t>(domain_id);
#endif

size_t length = snprintf(nullptr, 0, "enclave=%s;", enclave) + 1;
participantAttrs.rtps.userData.resize(length);
Expand Down