From a9f5fda6560f766234d65b3b1bc34f1f21889f53 Mon Sep 17 00:00:00 2001 From: ivanpauno Date: Tue, 26 Mar 2019 15:39:44 -0300 Subject: [PATCH] Corrected with PR comments --- rmw_fastrtps_shared_cpp/src/rmw_publisher.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/rmw_fastrtps_shared_cpp/src/rmw_publisher.cpp b/rmw_fastrtps_shared_cpp/src/rmw_publisher.cpp index 6885831dd..469e8faf3 100644 --- a/rmw_fastrtps_shared_cpp/src/rmw_publisher.cpp +++ b/rmw_fastrtps_shared_cpp/src/rmw_publisher.cpp @@ -118,7 +118,7 @@ __rmw_publisher_get_actual_qos( if (fastrtps_pub == nullptr) { return RMW_RET_ERROR; } - const eprosima::fastrtps::PublisherAttributes attributes = + const eprosima::fastrtps::PublisherAttributes & attributes = fastrtps_pub->getAttributes(); switch (attributes.topic.historyQos.kind) { @@ -129,7 +129,7 @@ __rmw_publisher_get_actual_qos( qos->history = RMW_QOS_POLICY_HISTORY_KEEP_ALL; break; default: - qos->history = RMW_QOS_POLICY_HISTORY_SYSTEM_DEFAULT; + qos->history = RMW_QOS_POLICY_HISTORY_UNKNOWN; break; } switch (attributes.qos.m_durability.kind) { @@ -140,7 +140,7 @@ __rmw_publisher_get_actual_qos( qos->durability = RMW_QOS_POLICY_DURABILITY_VOLATILE; break; default: - qos->durability = RMW_QOS_POLICY_DURABILITY_SYSTEM_DEFAULT; + qos->durability = RMW_QOS_POLICY_DURABILITY_UNKNOWN; break; } switch (attributes.qos.m_reliability.kind) { @@ -151,7 +151,7 @@ __rmw_publisher_get_actual_qos( qos->reliability = RMW_QOS_POLICY_RELIABILITY_RELIABLE; break; default: - qos->reliability = RMW_QOS_POLICY_RELIABILITY_SYSTEM_DEFAULT; + qos->reliability = RMW_QOS_POLICY_RELIABILITY_UNKNOWN; break; } qos->depth = static_cast(attributes.topic.historyQos.depth);