diff --git a/include/fastdds/rtps/builtin/data/ParticipantBuiltinTopicData.hpp b/include/fastdds/rtps/builtin/data/ParticipantBuiltinTopicData.hpp index 8306a5d33f9..e9c255ce92b 100644 --- a/include/fastdds/rtps/builtin/data/ParticipantBuiltinTopicData.hpp +++ b/include/fastdds/rtps/builtin/data/ParticipantBuiltinTopicData.hpp @@ -31,23 +31,25 @@ namespace rtps { struct ParticipantBuiltinTopicData { //! Constructor from ParticipantBuiltinTopicData - ParticipantBuiltinTopicData(const ParticipantBuiltinTopicData& pdata) - : key(pdata.key) - , user_data(pdata.user_data) - , guid(pdata.guid) - , properties(pdata.properties) - , participant_name(pdata.participant_name) - , metatraffic_locators(pdata.metatraffic_locators) - , default_locators(pdata.default_locators) - , lease_duration(pdata.lease_duration) - , vendor_id(pdata.vendor_id) - , domain_id(pdata.domain_id) + ParticipantBuiltinTopicData( + const ParticipantBuiltinTopicData& pdata) + : key(pdata.key) + , user_data(pdata.user_data) + , guid(pdata.guid) + , properties(pdata.properties) + , participant_name(pdata.participant_name) + , metatraffic_locators(pdata.metatraffic_locators) + , default_locators(pdata.default_locators) + , lease_duration(pdata.lease_duration) + , vendor_id(pdata.vendor_id) + , domain_id(pdata.domain_id) { } //! Default constructor ParticipantBuiltinTopicData() - {} + { + } //! Builtin topic Key BuiltinTopicKey_t key; diff --git a/src/cpp/rtps/builtin/data/ProxyDataConverters.cpp b/src/cpp/rtps/builtin/data/ProxyDataConverters.cpp index ac9d85ef4ed..f7a5a7e5cd7 100644 --- a/src/cpp/rtps/builtin/data/ProxyDataConverters.cpp +++ b/src/cpp/rtps/builtin/data/ProxyDataConverters.cpp @@ -44,9 +44,9 @@ static void from_proxy_to_builtin( builtin_key_value[0] = 0; builtin_key_value[1] = 0; builtin_key_value[2] = static_cast(entity_id.value[0]) << 24 - | static_cast(entity_id.value[1]) << 16 - | static_cast(entity_id.value[2]) << 8 - | static_cast(entity_id.value[3]); + | static_cast(entity_id.value[1]) << 16 + | static_cast(entity_id.value[2]) << 8 + | static_cast(entity_id.value[3]); } static void from_proxy_to_builtin( @@ -54,17 +54,17 @@ static void from_proxy_to_builtin( BuiltinTopicKeyValue& dds_key) { dds_key[0] = static_cast(guid_prefix.value[0]) << 24 - | static_cast(guid_prefix.value[1]) << 16 - | static_cast(guid_prefix.value[2]) << 8 - | static_cast(guid_prefix.value[3]); + | static_cast(guid_prefix.value[1]) << 16 + | static_cast(guid_prefix.value[2]) << 8 + | static_cast(guid_prefix.value[3]); dds_key[1] = static_cast(guid_prefix.value[4]) << 24 - | static_cast(guid_prefix.value[5]) << 16 - | static_cast(guid_prefix.value[6]) << 8 - | static_cast(guid_prefix.value[7]); + | static_cast(guid_prefix.value[5]) << 16 + | static_cast(guid_prefix.value[6]) << 8 + | static_cast(guid_prefix.value[7]); dds_key[2] = static_cast(guid_prefix.value[8]) << 24 - | static_cast(guid_prefix.value[9]) << 16 - | static_cast(guid_prefix.value[10]) << 8 - | static_cast(guid_prefix.value[11]); + | static_cast(guid_prefix.value[9]) << 16 + | static_cast(guid_prefix.value[10]) << 8 + | static_cast(guid_prefix.value[11]); } void from_proxy_to_builtin( diff --git a/src/cpp/rtps/builtin/discovery/participant/PDP.cpp b/src/cpp/rtps/builtin/discovery/participant/PDP.cpp index b33028fba08..d771a83e482 100644 --- a/src/cpp/rtps/builtin/discovery/participant/PDP.cpp +++ b/src/cpp/rtps/builtin/discovery/participant/PDP.cpp @@ -1340,7 +1340,7 @@ void PDP::actions_on_remote_participant_removed( bool should_be_ignored = false; listener->on_participant_discovery(mp_RTPSParticipant->getUserRTPSParticipant(), reason, - std::move(info), should_be_ignored); + std::move(info), should_be_ignored); } { diff --git a/test/blackbox/api/dds-pim/PubSubReader.hpp b/test/blackbox/api/dds-pim/PubSubReader.hpp index 230125aa5c4..17b5567f270 100644 --- a/test/blackbox/api/dds-pim/PubSubReader.hpp +++ b/test/blackbox/api/dds-pim/PubSubReader.hpp @@ -1686,7 +1686,8 @@ class PubSubReader } void setOnDiscoveryFunction( - std::function f) + std::function f) { onDiscovery_ = f; } @@ -2126,7 +2127,8 @@ class PubSubReader std::string participant_profile_ = ""; std::string datareader_profile_ = ""; - std::function onDiscovery_; + std::function onDiscovery_; std::function onEndpointDiscovery_; //! True to take data from history. On False, read_ is checked. diff --git a/test/blackbox/common/BlackboxTestsDiscovery.cpp b/test/blackbox/common/BlackboxTestsDiscovery.cpp index c35533345e4..c3b4f220faa 100644 --- a/test/blackbox/common/BlackboxTestsDiscovery.cpp +++ b/test/blackbox/common/BlackboxTestsDiscovery.cpp @@ -891,7 +891,8 @@ TEST_P(Discovery, PubSubAsReliableHelloworldParticipantDiscovery) ASSERT_TRUE(writer.isInitialized()); int count = 0; - reader.setOnDiscoveryFunction([&writer, &count](const ParticipantBuiltinTopicData& info, PARTICIPANT_DISCOVERY_STATUS status) -> bool + reader.setOnDiscoveryFunction([&writer, &count](const ParticipantBuiltinTopicData& info, + PARTICIPANT_DISCOVERY_STATUS status) -> bool { if (info.guid == writer.participant_guid()) { @@ -936,7 +937,8 @@ TEST_P(Discovery, PubSubAsReliableHelloworldUserData) ASSERT_TRUE(writer.isInitialized()); - reader.setOnDiscoveryFunction([&writer](const ParticipantBuiltinTopicData& info, PARTICIPANT_DISCOVERY_STATUS /*status*/) -> bool + reader.setOnDiscoveryFunction([&writer](const ParticipantBuiltinTopicData& info, + PARTICIPANT_DISCOVERY_STATUS /*status*/) -> bool { if (info.guid == writer.participant_guid()) { diff --git a/test/blackbox/common/BlackboxTestsSecurity.cpp b/test/blackbox/common/BlackboxTestsSecurity.cpp index 46e7100444b..637b98b4b3c 100644 --- a/test/blackbox/common/BlackboxTestsSecurity.cpp +++ b/test/blackbox/common/BlackboxTestsSecurity.cpp @@ -2724,7 +2724,8 @@ TEST_P(Security, BuiltinAuthenticationAndCryptoPlugin_user_data) sub_property_policy.properties().emplace_back("rtps.endpoint.submessage_protection_kind", "ENCRYPT"); sub_property_policy.properties().emplace_back("rtps.endpoint.payload_protection_kind", "ENCRYPT"); - reader.setOnDiscoveryFunction([&writer](const ParticipantBuiltinTopicData& info, PARTICIPANT_DISCOVERY_STATUS /*status*/) -> bool + reader.setOnDiscoveryFunction([&writer](const ParticipantBuiltinTopicData& info, + PARTICIPANT_DISCOVERY_STATUS /*status*/) -> bool { if (info.guid == writer.participant_guid()) { diff --git a/test/blackbox/common/DDSBlackboxTestsTransportSHMUDP.cpp b/test/blackbox/common/DDSBlackboxTestsTransportSHMUDP.cpp index de680e8de2f..2a0fadf3792 100644 --- a/test/blackbox/common/DDSBlackboxTestsTransportSHMUDP.cpp +++ b/test/blackbox/common/DDSBlackboxTestsTransportSHMUDP.cpp @@ -207,7 +207,9 @@ static void shm_metatraffic_test( PubSubWriter writer(topic_name + "/" + value); PubSubReader reader(topic_name + "/" + value); - auto discovery_checker = [unicast, multicast](const eprosima::fastdds::rtps::ParticipantBuiltinTopicData& info, eprosima::fastdds::rtps::PARTICIPANT_DISCOVERY_STATUS /*status*/) + auto discovery_checker = + [unicast, multicast](const eprosima::fastdds::rtps::ParticipantBuiltinTopicData& info, + eprosima::fastdds::rtps::PARTICIPANT_DISCOVERY_STATUS /*status*/) { check_shm_locators(info, unicast, multicast); return true; diff --git a/test/mock/rtps/RTPSParticipantImpl/rtps/participant/RTPSParticipantImpl.h b/test/mock/rtps/RTPSParticipantImpl/rtps/participant/RTPSParticipantImpl.h index 9e07651f032..db20064a792 100644 --- a/test/mock/rtps/RTPSParticipantImpl/rtps/participant/RTPSParticipantImpl.h +++ b/test/mock/rtps/RTPSParticipantImpl/rtps/participant/RTPSParticipantImpl.h @@ -80,7 +80,9 @@ class MockParticipantListener : public RTPSParticipantListener on_participant_discovery_mock(participant, status, info, should_be_ignored); } - MOCK_METHOD4(on_participant_discovery_mock, void (RTPSParticipant*, PARTICIPANT_DISCOVERY_STATUS, const ParticipantBuiltinTopicData&, bool&)); + MOCK_METHOD4(on_participant_discovery_mock, + void (RTPSParticipant*, PARTICIPANT_DISCOVERY_STATUS, const ParticipantBuiltinTopicData&, + bool&)); #if HAVE_SECURITY void onParticipantAuthentication(