Skip to content

Commit

Permalink
Make sure rmw_publisher_options is initialized in to_rcl_publisher_op…
Browse files Browse the repository at this point in the history
…tions.

Signed-off-by: ChenYing Kuo <evshary@gmail.com>
  • Loading branch information
evshary authored and hidmic committed May 21, 2020
1 parent 64bdef6 commit b9ea4c3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rclcpp/include/rclcpp/publisher_options.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ struct PublisherOptionsWithAllocator : public PublisherOptionsBase
rcl_publisher_options_t
to_rcl_publisher_options(const rclcpp::QoS & qos) const
{
rcl_publisher_options_t result;
rcl_publisher_options_t result = rcl_publisher_get_default_options();
using AllocatorTraits = std::allocator_traits<Allocator>;
using MessageAllocatorT = typename AllocatorTraits::template rebind_alloc<MessageT>;
auto message_alloc = std::make_shared<MessageAllocatorT>(*this->get_allocator().get());
Expand Down

0 comments on commit b9ea4c3

Please sign in to comment.