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:
authorCampbell Barton <ideasman42@gmail.com>2012-12-18 21:06:31 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-12-18 21:06:31 +0400
commite0d585b6c9f7187e8537193b41be10fba60b3a27 (patch)
tree8e78c6fffc2210781ea4912f63981c7b91649388 /source/blender/windowmanager/intern/wm_operators.c
parent63731453e2583c1e64d5d631b855559ce6ec0862 (diff)
fix for crash in recent changes, missing NULL check
Diffstat (limited to 'source/blender/windowmanager/intern/wm_operators.c')
-rw-r--r--source/blender/windowmanager/intern/wm_operators.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/source/blender/windowmanager/intern/wm_operators.c b/source/blender/windowmanager/intern/wm_operators.c
index 5d9819689d3..cd3d5c97f99 100644
--- a/source/blender/windowmanager/intern/wm_operators.c
+++ b/source/blender/windowmanager/intern/wm_operators.c
@@ -615,13 +615,17 @@ static char *wm_prop_pystring_from_context(bContext *C, PointerRNA *ptr, Propert
if (member_found) {
prop_str = RNA_path_property_py(ptr, prop, index);
- ret = BLI_sprintfN("bpy.context.%s.%s", member_found, prop_str);
- MEM_freeN(prop_str);
+ if (prop_str) {
+ ret = BLI_sprintfN("bpy.context.%s.%s", member_found, prop_str);
+ MEM_freeN(prop_str);
+ }
}
else if (member_id) {
prop_str = RNA_path_struct_property_py(ptr, prop, index);
- ret = BLI_sprintfN("bpy.context.%s.%s", member_id, prop_str);
- MEM_freeN(prop_str);
+ if (prop_str) {
+ ret = BLI_sprintfN("bpy.context.%s.%s", member_id, prop_str);
+ MEM_freeN(prop_str);
+ }
}
BLI_freelistN(&lb);