[Bf-blender-cvs] [825b015] master: Fix T44348: Blender crashes when selecting bone from inactive scene in outliner

Sergey Sharybin noreply at git.blender.org
Tue Apr 14 10:25:38 CEST 2015


Commit: 825b015e9218810ae2011df6cf4b67920ad9295d
Author: Sergey Sharybin
Date:   Tue Apr 14 13:24:17 2015 +0500
Branches: master
https://developer.blender.org/rB825b015e9218810ae2011df6cf4b67920ad9295d

Fix T44348: Blender crashes when selecting bone from inactive scene in outliner

Pose is not guaranteed to be existing in object, so can't be used for selection
flag clear. Use bones themselves for that.

===================================================================

M	source/blender/editors/space_outliner/outliner_select.c

===================================================================

diff --git a/source/blender/editors/space_outliner/outliner_select.c b/source/blender/editors/space_outliner/outliner_select.c
index 6050b66..e52c68b 100644
--- a/source/blender/editors/space_outliner/outliner_select.c
+++ b/source/blender/editors/space_outliner/outliner_select.c
@@ -554,10 +554,12 @@ static eOLDrawState tree_element_active_bone(
 			Object *ob = OBACT;
 			if (ob) {
 				if (set != OL_SETSEL_EXTEND) {
-					bPoseChannel *pchannel;
 					/* single select forces all other bones to get unselected */
-					for (pchannel = ob->pose->chanbase.first; pchannel; pchannel = pchannel->next)
-						pchannel->bone->flag &= ~(BONE_TIPSEL | BONE_SELECTED | BONE_ROOTSEL);
+					Bone *bone;
+					for (bone = arm->bonebase.first; bone != NULL; bone = bone->next) {
+						bone->flag &= ~(BONE_TIPSEL | BONE_SELECTED | BONE_ROOTSEL);
+						do_outliner_bone_select_recursive(arm, bone, false);
+					}
 				}
 			}




More information about the Bf-blender-cvs mailing list