Page MenuHome

Fix T61051: crash with multi-object mixed mode snapping

Authored by Philipp Oeser (lichtwerk) on Jan 31 2019, 1:04 PM.



Fix T61051: crash with multi-object mixed mode snapping

rBec3357e03ab1 introduced multi-object snapping.
Seems like this was done without mixed-mode selections in mind.

So code assumes that all selected objects are actually armatures [which can fail].
In 2.7 this was not a problem, because code only took active object into account, 2.8 was iterating over all selected_editable_objects.

Now just iterate over objects in posemode instead

Diff Detail

rB Blender

Event Timeline

note: alternatively we could use BKE_view_layer_array_from_objects_in_mode instead of CTX_DATA_BEGIN (C, Object *, ob, selected_editable_objects) to be a bit more precise from the start?

Dalai Felinto (dfelinto) requested changes to this revision.Jan 31 2019, 10:11 PM

BKE_view_layer_array_from_objects_in_mode is better indeed.
Besides remember to make comments full sentences, with capital letter at the beginning and a full stop in the end.

This revision now requires changes to proceed.Jan 31 2019, 10:11 PM

use BKE_view_layer_array_from_objects_in_mode

Philipp Oeser (lichtwerk) edited the summary of this revision. (Show Details)
This revision was not accepted when it landed; it landed in state Needs Review.Feb 6 2019, 9:49 AM
This revision was automatically updated to reflect the committed changes.