You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(rclcpp_action): Fixed race condition in Client
Some background information: is_ready, take_data and execute data
may be called from different threads in any order. The code in the old
state expected them to be called in series, without interruption.
This lead to multiple race conditions, as the state of the pimpl objects
was altered by the three functions in a non thread safe way.
This commit fixed this by
- Introducing a data queue that is filled in is_ready
- take_data from now only pops the front element of the data queue
- A backlog of events if held in num_unreported_events_ which will be
reported by future calls of is_ready
Signed-off-by: Janosch Machowinski <[email protected]>
0 commit comments