Skip to content

Commit

Permalink
fix(behavior_path_planner): prevent crashes with the drivable area ex…
Browse files Browse the repository at this point in the history
…pansion (#917)
  • Loading branch information
maxime-clem authored Oct 6, 2023
1 parent 7926195 commit b5e0d3d
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ polygon_t createExpansionPolygon(
boost::geometry::buffer(
base_ls, polygons, distance_strategy, strategy::side_straight(), strategy::join_miter(),
strategy::end_flat(), strategy::point_square());
return polygons.front();
return polygons.empty() ? polygon_t{} : polygons.front();
}

std::array<double, 3> calculate_arc_length_range_and_distance(
Expand Down

0 comments on commit b5e0d3d

Please sign in to comment.