Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans Goudey <h.goudey@me.com>2022-03-04 19:11:56 +0300
committerHans Goudey <h.goudey@me.com>2022-03-04 19:11:56 +0300
commit295d5c6ef5b9a464cfdd52eaffb3c0e710ad4155 (patch)
tree13a0296620920ae20f7107ad0cfcbe6dbc561fb7 /source/blender/blenkernel/intern/curve_eval.cc
parent1763ffa0be4806949a2644a4a520647c9a1eefbd (diff)
Fix T96164: Crash with curve domain attributes
When converting from the new type to the old, the curve domain attributes weren't properly resized, so their data was not properly allocated.
Diffstat (limited to 'source/blender/blenkernel/intern/curve_eval.cc')
-rw-r--r--source/blender/blenkernel/intern/curve_eval.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/curve_eval.cc b/source/blender/blenkernel/intern/curve_eval.cc
index d6525a11cff..1ffbed39216 100644
--- a/source/blender/blenkernel/intern/curve_eval.cc
+++ b/source/blender/blenkernel/intern/curve_eval.cc
@@ -436,6 +436,8 @@ std::unique_ptr<CurveEval> curves_to_curve_eval(const Curves &curves)
curve_eval->add_spline(std::move(spline));
}
+ curve_eval->attributes.reallocate(curve_eval->splines().size());
+
CurveComponentLegacy dst_component;
dst_component.replace(curve_eval.get(), GeometryOwnershipType::Editable);