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:
authorTon Roosendaal <ton@blender.org>2011-02-19 21:53:08 +0300
committerTon Roosendaal <ton@blender.org>2011-02-19 21:53:08 +0300
commit43d362fcc8592cede760a56cf863a0c3eb80ff5f (patch)
tree46e31bef9f94fd0f4f4629aef5eb36597983f4d5 /source/blender/editors
parent9d81d5f7ac69d209325cc1f644c5c06a600483b1 (diff)
Bugfix #26150
Crash in hovering over the menu "Pose -> Poselib" sub-items. NULL context passed on to function and read before the test.
Diffstat (limited to 'source/blender/editors')
-rw-r--r--source/blender/editors/armature/poselib.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/source/blender/editors/armature/poselib.c b/source/blender/editors/armature/poselib.c
index bfe33299043..9577c45de50 100644
--- a/source/blender/editors/armature/poselib.c
+++ b/source/blender/editors/armature/poselib.c
@@ -470,10 +470,11 @@ void POSELIB_OT_pose_add (wmOperatorType *ot)
/* ----- */
+/* can be called with C == NULL */
static EnumPropertyItem *poselib_stored_pose_itemf(bContext *C, PointerRNA *UNUSED(ptr), int *free)
{
- Object *ob= get_poselib_object(C);
- bAction *act= (ob) ? ob->poselib : NULL;
+ Object *ob;
+ bAction *act;
TimeMarker *marker;
EnumPropertyItem *item= NULL, item_tmp= {0};
int totitem= 0;
@@ -483,6 +484,9 @@ static EnumPropertyItem *poselib_stored_pose_itemf(bContext *C, PointerRNA *UNUS
return DummyRNA_DEFAULT_items;
}
+ ob= get_poselib_object(C);
+ act= (ob) ? ob->poselib : NULL;
+
/* check that the action exists */
if (act) {
/* add each marker to the list */