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:
authorBastien Montagne <montagne29@wanadoo.fr>2016-08-06 00:33:22 +0300
committerBastien Montagne <montagne29@wanadoo.fr>2016-08-06 00:36:43 +0300
commitdf7be614382ba6ce58a2fab4ff6b4ab0b09b0a9f (patch)
treec101ad8fdc76feddaf74222a7f944b1c4a9fde50
parent8adcd93769800afb0deb989c6e077e5994478fb6 (diff)
Fix T49023: Segfault when switching brushes while renaming another brush.
rna_GPencilBrush_name_set() was trying to use a mere bGPDbrush as a complete ToolSettings, was doomed to fail...
-rw-r--r--source/blender/makesrna/intern/rna_scene.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/makesrna/intern/rna_scene.c b/source/blender/makesrna/intern/rna_scene.c
index 8a4f41d963d..b6abe983060 100644
--- a/source/blender/makesrna/intern/rna_scene.c
+++ b/source/blender/makesrna/intern/rna_scene.c
@@ -542,7 +542,7 @@ static void rna_GPencilBrush_index_range(PointerRNA *ptr, int *min, int *max, in
static void rna_GPencilBrush_name_set(PointerRNA *ptr, const char *value)
{
- ToolSettings *ts = (ToolSettings *) ptr->data;
+ ToolSettings *ts = ((Scene *) ptr->id.data)->toolsettings;
bGPDbrush *brush = ptr->data;
/* copy the new name into the name slot */