forked from bartvdbraak/blender
Fix #122538: crash calling curves_copy_point_selection with empty selection
This is accessing curve offsets, which don't have entries for empty geometry. Pull Request: https://projects.blender.org/blender/blender/pulls/122499
This commit is contained in:
parent
28cef56ad2
commit
b588daa68b
@ -1209,6 +1209,9 @@ CurvesGeometry curves_copy_point_selection(
|
||||
threading::parallel_invoke(
|
||||
dst_curves.curves_num() > 1024,
|
||||
[&]() {
|
||||
if (curves_to_copy.is_empty()) {
|
||||
return;
|
||||
}
|
||||
MutableSpan<int> new_curve_offsets = dst_curves.offsets_for_write();
|
||||
array_utils::gather(
|
||||
curve_point_counts.as_span(), curves_to_copy, new_curve_offsets.drop_back(1));
|
||||
|
Loading…
Reference in New Issue
Block a user