Open oKermorgant opened 1 year ago
@oKermorgant You probably should signoff on your commits: https://github.com/ros2/ros1_bridge/pull/411/checks?check_run_id=14855763467
The last push is to handle vector<bool>
that lie in services, the code was generated elsewhere.
In order to handle this I had to use index-based for-loops instead of iterators (you cannot iterate on a vector<bool>
and hope to get a pointer to a bool...).
fixes the bool list issue for me :+1: (setup: Ubuntu 24.04, ROS 2 Jazzy / ROS Noetic)
Thanks @oKermorgant !
This PR modifies the
interface_factories
template file and adds a special case to handle fields which arestd:vector<bool>
.The current approach to stream a
std::vector
is tomemcpy
its content into/from the stream.Unfortunately, it does not work for
std::vector<bool>
as there is not a singlebool
inside such.In this PR the template file generates a special call when a
vector<bool>
is detected.This should answer https://github.com/ros2/ros1_bridge/issues/391, https://github.com/ros2/ros1_bridge/issues/393