Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions rclcpp_async/include/rclcpp_async/co_context.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -500,12 +500,7 @@ void SendGoalAwaiter<ActionT>::await_suspend(std::coroutine_handle<> h)
state->stream->client_ = client;
state->result = Result<std::shared_ptr<GoalStream<ActionT>>>::Ok(state->stream);
}
// Use post() instead of resume() to defer coroutine resumption.
// rclcpp_action holds goal_requests_mutex during this callback
// (Jazzy bug: https://github.com/ros2/rclcpp/issues/2796).
// Resuming synchronously here would deadlock if the coroutine
// immediately calls async_send_goal again.
ctx.post([&ctx, h]() { ctx.resume(h); });
ctx.resume(h);
};

client->async_send_goal(goal, options);
Expand Down
Loading