Fix T94085.
Exit the code early if stroke list is empty
Otherwise exception will be thrown for writing at unallocated memory
Details
Details
- Reviewers
- None
- Maniphest Tasks
- T94085: Calling bpy.ops.curve.draw with an empty stroke list causes a segfault
Diff Detail
Diff Detail
- Repository
- rB Blender
Event Timeline
Comment Actions
Thanks for the patch, I ended up committing an alternative fix.
- Exit in curve_draw_init since it allocates memory which needs to be freed.
- I don't think RNA_struct_property_is_set is correct as a property could be set but still to an empty list.