From 34d8a6e5144d6caa3f0318435d973bd53a286e25 Mon Sep 17 00:00:00 2001 From: yutaka Date: Tue, 30 Aug 2022 16:14:31 +0900 Subject: [PATCH] feat(obstacle_cruise_planner): fix stop condition Signed-off-by: yutaka --- planning/obstacle_cruise_planner/src/planner_interface.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/planning/obstacle_cruise_planner/src/planner_interface.cpp b/planning/obstacle_cruise_planner/src/planner_interface.cpp index 9166bec372e55..8302736cb6149 100644 --- a/planning/obstacle_cruise_planner/src/planner_interface.cpp +++ b/planning/obstacle_cruise_planner/src/planner_interface.cpp @@ -102,7 +102,7 @@ Trajectory PlannerInterface::generateStopTrajectory( // Get Closest Stop Obstacle const auto closest_stop_obstacle = obstacle_cruise_utils::getClosestStopObstacle(planner_data.traj, planner_data.target_obstacles); - if (!closest_stop_obstacle && closest_stop_obstacle->collision_points.empty()) { + if (!closest_stop_obstacle || closest_stop_obstacle->collision_points.empty()) { // delete marker const auto markers = motion_utils::createDeletedStopVirtualWallMarker(planner_data.current_time, 0);