Skip to content

Commit

Permalink
Enable assert liveliness on publisher
Browse files Browse the repository at this point in the history
  • Loading branch information
Emerson Knapp committed Jun 26, 2019
1 parent 15a4406 commit ed7cfb5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
5 changes: 2 additions & 3 deletions rmw_fastrtps_shared_cpp/src/qos.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -161,10 +161,9 @@ bool
is_valid_qos(const rmw_qos_profile_t & qos_policies)
{
if (qos_policies.liveliness == RMW_QOS_POLICY_LIVELINESS_MANUAL_BY_NODE ||
qos_policies.liveliness == RMW_QOS_POLICY_LIVELINESS_MANUAL_BY_TOPIC ||
!is_time_default(qos_policies.liveliness_lease_duration))
&& !is_time_default(qos_policies.liveliness_lease_duration))
{
RMW_SET_ERROR_MSG("Liveliness QoS is not yet supported for fastrtps.");
RMW_SET_ERROR_MSG("Liveliness policy MANUAL_BY_NODE is not yet supported for fastrtps.");
return false;
}
return true;
Expand Down
6 changes: 2 additions & 4 deletions rmw_fastrtps_shared_cpp/src/rmw_publisher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,8 @@ __rmw_publisher_assert_liveliness(
return RMW_RET_ERROR;
}

// info->publisher_->assert_liveliness();
RMW_SET_ERROR_MSG("assert_liveliness() of publisher is currently not supported");

return RMW_RET_UNSUPPORTED;
info->publisher_->assert_liveliness();
return RMW_RET_OK;
}

rmw_ret_t
Expand Down

0 comments on commit ed7cfb5

Please sign in to comment.