Skip to content

Commit

Permalink
fix merge
Browse files Browse the repository at this point in the history
  • Loading branch information
jplapp committed Sep 27, 2024
1 parent 4f4aee6 commit 736e95c
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class TemporaryDirectoryFixture : public Test
public:
TemporaryDirectoryFixture()
{
temporary_dir_path_ = rcpputils::fs::create_temporary_directory("tmp_test_dir_").string();
temporary_dir_path_ = rcpputils::fs::create_temp_directory("tmp_test_dir_").string();
}

~TemporaryDirectoryFixture() override
Expand Down
17 changes: 10 additions & 7 deletions rosbag2_transport/src/rosbag2_transport/recorder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -665,15 +665,18 @@ RecorderImpl::create_subscription(
topic_name, \
qos, \
[this, topic_name, topic_type, serializer](const MSG_TYPE::ConstSharedPtr message, const rclcpp::MessageInfo & mi) { \
rclcpp::SerializedMessage serialized_msg; \
serializer->serialize_message(message.get(), &serialized_msg); \
auto serialized_msg = std::make_shared<rclcpp::SerializedMessage>(); \
serializer->serialize_message(message.get(), serialized_msg.get()); \
if (!paused_.load()) { \
writer_->write( \
std::move(serialized_msg), topic_name, topic_type, \
mi.get_rmw_message_info().received_timestamp, \
mi.get_rmw_message_info().source_timestamp); \
writer_->write( \
std::static_pointer_cast<const rclcpp::SerializedMessage>(serialized_msg), \
topic_name, \
topic_type, \
mi.get_rmw_message_info().received_timestamp, \
mi.get_rmw_message_info().source_timestamp \
); \
} \
}); \
});\
return subscription; \
}
// List of all message types with their corresponding string representations
Expand Down
2 changes: 1 addition & 1 deletion rosbag2_transport/test/rosbag2_transport/test_rewrite.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ class TestRewrite : public Test, public WithParamInterface<std::string>
public:
TestRewrite()
{
auto tmp_dir = rcpputils::fs::create_temporary_directory("test_bag_rewrite");
auto tmp_dir = rcpputils::fs::create_temp_directory("test_bag_rewrite");
output_dir_ = fs::path(tmp_dir.string());
storage_id_ = GetParam();
bags_path_ = fs::path(_SRC_RESOURCES_DIR_PATH) / storage_id_;
Expand Down

0 comments on commit 736e95c

Please sign in to comment.