It was complaining about an unknown macro RCLCPP_SMART_PTR_DEFINITIONS.
Passing rclcpp include directories to cppcheck resolves the errors
reported in rclcpp_action and rclcpp_lifecycle.
Signed-off-by: Jacob Perron <jacob@openrobotics.org>
This fixes a cppcheck error that was detected when including the rclcpp headers in rclcpp_action and rclcpp_lifecycle.
It is not clear to me why cppcheck does not report the unitialized member when testing rclcpp directly.
Signed-off-by: Jacob Perron <jacob@openrobotics.org>
* Switch to using new rcutils_strerror.
Also increase timeouts for test_logging, which should reduce flakes on Windows.
Signed-off-by: Chris Lalancette <clalancette@openrobotics.org>
Capturing a cached reference allows a clock object that is not a local
(e.g. the one returned by Node::get_clock()) to be passed to the throttle
logging macro.
Signed-off-by: Matt Schickler <mschickler@gmail.com>
Co-Authored-By: Ivan Santiago Paunovic <ivanpauno@ekumenlabs.com>
The function was previously documented as being deprecated, but this change adds compiler warnings if it is used.
Ignore compiler warnings where the function is being tested and change to the preferred usage elsewhere.
Signed-off-by: Jacob Perron <jacob@openrobotics.org>
Fix for a build error on 32-bit Windows. Member functions use the
__thiscall convention by default which is incompatible with __cdecl.
Signed-off-by: Sean Kelly <sean@seankelly.dev>
* Assigning make_shared result to variables in test
Signed-off-by: Stephen Brawner <brawner@gmail.com>
* PR fixup
Signed-off-by: Stephen Brawner <brawner@gmail.com>
Otherwise, rclcpp_components_register_node() fails if used from a fat archive.
Related to https://github.com/ros2/ros2/issues/606.
Signed-off-by: Jacob Perron <jacob@openrobotics.org>
* New README
* dashing to eloquent for api docs
* remove "accepted"
Co-Authored-By: Chris Lalancette <clalancette@openrobotics.org>
* components > APIs
Co-Authored-By: Chris Lalancette <clalancette@openrobotics.org>
* Add disable_rosout into NodeOptions.
Signed-off-by: Barry Xu <Barry.Xu@sony.com>
* Update comments
Signed-off-by: Barry Xu <Barry.Xu@sony.com>
* keep implementation consistency by using enable_rosout name
Signed-off-by: Barry Xu <Barry.Xu@sony.com>
* fix error comment
Signed-off-by: Barry Xu <Barry.Xu@sony.com>
* add test case for node options
Signed-off-by: Barry Xu <Barry.Xu@sony.com>
* fix source about copy value and reset rcl_node_options, add more test cases
Signed-off-by: Barry Xu <Barry.Xu@sony.com>
To prevent the Executor::spin_some() method for potentially running
indefinitely long.
Distribution Statement A; OPSEC #2893
Signed-off-by: Roger Strain <rstrain@swri.org>
Whenever a call is made to `rclcpp_action::Client::wait_for_action_server`
a weak pointer to an Event object gets added to the graph_event_ vector
of the NodeGraph interface. This vector will be cleared on a node graph
change event, but if no such event occurs the weak pointer will be stuck
in the vector. Furthermore, if client code issues repeated calls to
`wait_for_action_server` the vector will keep growing.
The fix moves the Event object creation right after the early return from
`wait_for_action_server` so that the Event object is not created in the
case that the server is known to be present and therefore there is no
need to wait for a node graph change event to occur.
Signed-off-by: Adrian Stere <astere@clearpath.ai>